home *** CD-ROM | disk | FTP | other *** search
/ Aminet 40 / Aminet 40 (2000)(Schatztruhe)[!][Dec 2000].iso / Aminet / dev / c / ExtrasLib.lha / ExtrasLib / Docs / extras.doc next >
Encoding:
Text File  |  2000-09-30  |  71.6 KB  |  2,813 lines

  1. TABLE OF CONTENTS
  2.  
  3. extras.lib/--history--
  4. extras.lib/AddHotKey
  5. extras.lib/AllocProgressMeterA
  6. extras.lib/ArgYesNo
  7. extras.lib/boopsi_GetGInfo
  8. extras.lib/Busy
  9. extras.lib/CopyString
  10. extras.lib/db_EntryToNN
  11. extras.lib/db_GetEntryData
  12. extras.lib/db_NextEntry
  13. extras.lib/EnqueueName
  14. extras.lib/ex_CloseLibs
  15. extras.lib/ex_OpenLibs
  16. extras.lib/EZReq
  17. extras.lib/FindLine
  18. extras.lib/FreeProgressMeter
  19. extras.lib/ftos
  20. extras.lib/gui_GhostRect
  21. extras.lib/gui_MaxStrFontLen
  22. extras.lib/gui_StrFontLen
  23. extras.lib/gui_StrLength
  24. extras.lib/IsWhiteSpace
  25. extras.lib/key_Shifted
  26. extras.lib/key_Unshifted
  27. extras.lib/MultiAllocMemA
  28. extras.lib/MultiAllocPooledA
  29. extras.lib/MultiAllocVecA
  30. extras.lib/MultiFreeMemA
  31. extras.lib/MultiFreePooledA
  32. extras.lib/MultiFreeVecA
  33. extras.lib/NextNNStr
  34. extras.lib/nns_AddNNStr
  35. extras.lib/nns_GetNNData
  36. extras.lib/nns_NNStrLen
  37. extras.lib/NNString_Overview
  38. extras.lib/NotBusy
  39. extras.lib/OBSOLETE--datasheet--
  40. extras.lib/OBSOLETE_CheckInnerWindowSize
  41. extras.lib/OBSOLETE_CheckWindowSize
  42. extras.lib/OBSOLETE_GetGUIScale
  43. extras.lib/OBSOLETE_LG_AddGadgets
  44. extras.lib/OBSOLETE_LG_CreateGadgets
  45. extras.lib/OBSOLETE_LG_FreeGadgets
  46. extras.lib/OBSOLETE_LG_GetGadget
  47. extras.lib/OBSOLETE_LG_GetGadgetAttrs
  48. extras.lib/OBSOLETE_LG_RemoveGadgets
  49. extras.lib/OBSOLETE_LG_SetGadgetAttrs
  50. extras.lib/OBSOLETE_MakeGadgets
  51. extras.lib/OBSOLETEDrawBevelBoxes
  52. extras.lib/PD_PackData
  53. extras.lib/PD_UnpackData
  54. extras.lib/PhraseInStr
  55. extras.lib/ProcessTagList
  56. extras.lib/RenderText
  57. extras.lib/str_Strip
  58. extras.lib/StrIStr
  59. extras.lib/tag_AddTag
  60. extras.lib/tag_AddTags
  61. extras.lib/tag_AllocTags
  62. extras.lib/tag_ClearNumTags
  63. extras.lib/tag_ClearTags
  64. extras.lib/tag_CountUserTags
  65. extras.lib/tag_FreeTags
  66. extras.lib/tag_RemTag
  67. extras.lib/tag_TagDone
  68. extras.lib/tag_TagMore
  69. extras.lib/thread_EndThread
  70. extras.lib/thread_PutTMsg
  71. extras.lib/thread_PutTMsg_Sync
  72. extras.lib/thread_PutTMsg_TagList
  73. extras.lib/thread_StartThread
  74. extras.lib/UpdateProgressMeterA
  75. Macro/nns_ProcessNNStr
  76. extras.lib/--history--                                 extras.lib/--history--
  77.  
  78.    Versions
  79.        1.3 - thread_ functions made usable.
  80.  
  81. extras.lib/AddHotKey                                     extras.lib/AddHotKey
  82.  
  83.    NAME
  84.        AddHotKey -- Add a hotkey to a Broker.
  85.  
  86.    SYNOPSIS
  87.        cxobj = AddHotKey(Broker,BrokerPort,HotKey,ID)
  88.  
  89.        CxObj *AddHotKey(CxObj *,struct MsgPort *,STRPTR,ULONG)
  90.  
  91.    FUNCTION
  92.        Creates a hotkey for a broker.
  93.  
  94.    INPUTS
  95.        Broker     - Broker CxObj to attach hotkey to. 
  96.        BrokerPort - Broker's MsgPort.
  97.        HotKey     - Null terminated string.
  98.        ID         - Hot keys ID. 
  99.        
  100.    RESULT
  101.        pointer to a CxObj.
  102.  
  103.    EXAMPLE
  104.  
  105.    NOTES
  106.     requires commodities.library to be opened. 
  107.      commodities library already has HotKey()
  108.  
  109.    BUGS
  110.  
  111.    SEE ALSO
  112.  
  113. extras.lib/AllocProgressMeterA                 extras.lib/AllocProgressMeterA
  114.  
  115.    NAME
  116.        AllocProgressMeterA -- Allocate and initialize a progressmeter.
  117.        AllocProgressMeter -- varargs stub for AllocProgressMeterA().
  118.  
  119.    SYNOPSIS
  120.        meter = AllocProgressMeterA(TagList)
  121.  
  122.        ProgressMeter AllocProgressMeterA( struct TagItem *);
  123.  
  124.        meter = AllocProgressMeterA(Tag, ... )
  125.  
  126.        ProgressMeter AllocProgressMeterA( Tag, ...);
  127.  
  128.    FUNCTION
  129.        This function allocates and initializes a ProgressMeter.
  130.  
  131.    INPUTS
  132.        TagList - 
  133.          One of the following two are required.
  134.          PM_Screen - The screen to place the meter on.
  135.                      (struct Screen *)
  136.          PM_ParentWindow - The parent window of the meter.
  137.                            (struct Window *)
  138.                            
  139.          PM_MsgPort    - Already existing msgport to send the meter's
  140.                          window events through. (Not implemented)
  141.  
  142.          PM_TextAttr   - Font to use in the meter. defaults to the
  143.                          screen font. (struct TextAttr *)
  144.  
  145.          PM_LeftEdge   - Defaults to be centered on PM_ParentWindow
  146.          PM_TopEdge    - or PMScreen.
  147.          PM_MinWidth   - Set the minimum width of the meter's
  148.                          window.
  149.          PM_MinHeight  - Set the minimum height of the meter's
  150.                          window (Not implemented).
  151.  
  152.          PM_WinTitle   - Meter's Window title. (STRPTR) 
  153.  
  154.          PM_LowText    - default "0%"   (STRPTR)  
  155.          PM_HighText   - default "100%" (STRPTR)
  156.  
  157.          PM_MeterFormat - A printf style format string used inside the meter.
  158.                           default "%ld%%". (STRPTR) 
  159.          PM_MeterType   - How PM_MeterFormat is used, 
  160.                             PM_TYPE_PERCENTAGE - uses the percentage of
  161.                               where PM_MeterValue is between PM_LowValue and
  162.                               PM_HighValue for the argument of 
  163.                               PM_MeterFormat.
  164.                             PM_TYPE_NUMBER - Uses the meter's value for the 
  165.                               argument of PM_MeterFormat.
  166.                             PM_TYPE_STRING - Doens't process the meter's 
  167.                               value simply displays the text from 
  168.                               PM_MeterFormat
  169.          PM_MeterLabel    - The label above the meter.  default NULL 
  170.          PM_MinMeterWidth - The minimum meter bar width, the default minimum
  171.                             is 80
  172.  
  173.          PM_MeterPen      - default fillpen 
  174.          PM_MeterBgPen    - default backgroundpen 
  175.          PM_FormatPen     - default highlight text 
  176.          PM_MeterLabelPen - default highlight text 
  177.          PM_LowTextPen    - default text pen 
  178.          PM_HighTextPen   - default text pen 
  179.  
  180.          PM_MeterValue    - (IS) default   0 (LONG) 
  181.          PM_LowValue      - (IS) default   0 (LONG)  
  182.          PM_HighValue     - (IS) default 100 (LONG)
  183.  
  184.          PM_Ticks         -  Ticks to draw under the meter box
  185.                                defaults to 0 for none 
  186.  
  187.          PM_CancelButton - Create a Cancel button? (BOOL)
  188.          PM_CancelText   - Text for cancel button. default "Cancel". (STRPTR)
  189.          PM_QueryCancel  - (S) The number of time the user
  190.                            has pressed the cancel button since the last
  191.                            PM_QueryCancel (ULONG *)  
  192.  
  193.          the following three are not implemented 
  194.          PM_CancelID - Creates an IDCMP_GADGETUP event when the Cancel button
  195.                        is clicked. IntuiMessage->IAddress will be a pointer
  196.                        to a gadget whose GadgetID is taken from this tag.
  197.                        To be used in conjunctoin with the PM_MsgPort tag.
  198.          PM_CancelSigNum  - Sets a signal when the Cancel button is clicked 
  199.          PM_CancelSigTask - Task to signal (struct Task *)    
  200.  
  201.    RESULT
  202.        returns a pointer to a ProgressMeter. or NULL on failure.
  203.  
  204.    EXAMPLE
  205.  
  206.    NOTES
  207.      requires diskfont, exec, gadtools, graphics, intuition & utility
  208.      libraries to be open.
  209.  
  210.    BUGS
  211.        Currently uses SmartRefresh window.
  212.  
  213.    SEE ALSO
  214.        FreeProgressMeter(), UpdateProgressMeterA()
  215.  
  216. extras.lib/ArgYesNo                                       extras.lib/ArgYesNo
  217.  
  218.    NAME
  219.        ArgYesNo - Get a boolean tooltype value.
  220.  
  221.    SYNOPSIS
  222.        yes = ArgYesNo(TTypes,Entry,DefVal)
  223.  
  224.        BOOL ArgYesNo(UBYTE **, STRPTR, DefVal);
  225.  
  226.    FUNCTION
  227.        This function returns the value of a boolean tooltype.
  228.  
  229.    INPUTS
  230.        TTypes - a ToolTypes array returned by ArgArrayInit()
  231.        Entry - the entry to search for.
  232.        DefVal - the default boolean value.
  233.  
  234.    RESULT
  235.        This function only considers the first letter of the
  236.        of the value for the tooltype.  If the first letter
  237.        of the value for the tooltype is 'Y' 'y' 'T' or 't'
  238.        then this function returns 1, if the function finds
  239.        'N' 'n' 'F' or 'f' then it returns 0, if this function
  240.        finds any other character or cannot find the tooltype,
  241.        then the function returns the DefVal.
  242.  
  243.    NOTES
  244.        must link with amiga.lib
  245.  
  246.    SEE ALSO
  247.      amiga.lib/ArgArrayInit(), amiga.lib/ArgString(),
  248.      amiga.lib/ArgInt(), amiga.lib/ArgArrayDone()
  249. extras.lib/boopsi_GetGInfo                         extras.lib/boopsi_GetGInfo
  250.  
  251.    NAME
  252.        boopsi_GetGInfo -- Get the GadgetInfo pointer from common BOOPSI messa
  253. ges
  254.  
  255.    SYNOPSIS
  256.        ginfo = boopsi_GetGInfo(Message)
  257.  
  258.        struct GadgetInfo *boopsi_GetGInfo(Msg);
  259.  
  260.    FUNCTION
  261.        Gets the pointer to the GadgetInfo structure from a BOOPSI
  262.        message.
  263.  
  264.    INPUTS
  265.        Message - BOOPSI message pointer.
  266.  
  267.    RESULT
  268.        pointer to GadgetInfo structure or NULL.
  269.  
  270.    NOTES
  271.        Only handles OM_SET, OM_UPDATE, OM_NOTIFY, GM_HITTEST,
  272.        GM_RENDER, GM_GOACTIVE, GM_HANDLEINPUT, GM_GOINACTIVE
  273.        and GM_LAYOUT methods.
  274.  
  275.    BUGS
  276.  
  277.    SEE ALSO
  278.  
  279. extras.lib/Busy                                               extras.lib/Busy
  280.  
  281.    NAME
  282.        Busy -- displays busy pointer.
  283.  
  284.    SYNOPSIS
  285.        Busy(Window)
  286.  
  287.        void Busy(struct Window *);
  288.  
  289.    FUNCTION
  290.        Blocks input to a window by opening a requester.
  291.  
  292.    INPUTS
  293.        Window - 
  294.  
  295.    RESULT
  296.        None.
  297.  
  298.    NOTES
  299.        requires intuition.library to be open.
  300.  
  301.        This does not change the Window's IDCMP flags, so
  302.        unless you change them your still going to receive
  303.        input events.
  304.        This function does nothing in WB versions less than
  305.        3.0
  306.  
  307.    SEE ALSO
  308.        NotBusy()
  309.  
  310. extras.lib/CopyString                                   extras.lib/CopyString
  311.  
  312.    NAME
  313.        CopyString -- Copy a string
  314.  
  315.    SYNOPSIS
  316.        newstring = CopyString(Source, MemFlags)
  317.  
  318.        STRPTR CopyString(STRPTR, ULONG);
  319.  
  320.    FUNCTION
  321.        Allocates memory using AllocVec and copies a string.
  322.  
  323.    INPUTS
  324.        Source - the source string to copy
  325.        MemFlags - Memory flags see exec.library/AllocVec()
  326.  
  327.    RESULT
  328.        String pointer or NULL. 
  329.  
  330.    NOTES
  331.        newstring must be freed with FreeVec.
  332.  
  333.    SEE ALSO
  334.      exec.library/AllocVec(), exec.library/FreeVec()
  335.  
  336. extras.lib/db_EntryToNN                               extras.lib/db_EntryToNN
  337.  
  338.    NAME
  339.        db_EntryToNN -- Retrieve data from an ENTRY of a database.
  340.  
  341.    SYNOPSIS
  342.        STRPTR db_EntryToNN(BPTR File, STRPTR EntryName)
  343.  
  344.    FUNCTION
  345.        Get data from a Database, see db_GetEntryData().
  346.        All the data in the entry is put into an NNString.
  347.        The data can then be parsed with nns_GetNNData()
  348.  
  349. extras.lib/db_GetEntryData                         extras.lib/db_GetEntryData
  350.  
  351.    NAME
  352.        db_GetEntryData -- Retrieve data from an ENTRY of a database.
  353.  
  354.    SYNOPSIS
  355.        db_GetEntryDataA(File, EntryName, Items) -- NOT implemented --
  356.  
  357.        BOOL db_GetEntryDataA(BPTR, STRPTR struct EItem *);
  358.  
  359.        db_GetEntryData(File, EntryName, Items, ... )
  360.  
  361.        BOOL db_GetEntryData(BPTR, STRPTR, STRPTR, ... );
  362.  
  363.    FUNCTION
  364.        Retrieve data from a simple ENTRY based database.
  365.  
  366.    INPUTS
  367.        File - an AmigaDOS BPTR to a file.
  368.        Name - an array of struct Etems, the last struct EItem should have
  369.               it's Name field set to NULL. (see example)
  370.    RESULT
  371.        returns 0 on failure, possibly due to EOF, improper file format, or
  372.        lack of memory.  
  373.     
  374.        To support multiple occurances of an item Name in an Entry, this 
  375.        function returns NNStrings.  The strings are stored end to end in 
  376.        the order that they were read from the file.
  377.  
  378.        On success, each EItem.ReturnString either points to an NNString,
  379.        or NULL if no data for that Name was found.
  380.  
  381.        On failure, all EItem.ReturnStrings are NULL, and any data collected
  382.        is freed.
  383.  
  384.    EXAMPLE
  385.        STRPTR title,desc;
  386.        BPTR File;
  387.  
  388.        if(db_GetEntryData(File,"ENTRY",
  389.                             "TITLE"  ,&title,
  390.                             "DESC"   ,&desc,
  391.                                0))
  392.        {
  393.          if(title)
  394.          {
  395.            printf("%s - ",title);
  396.            FreeVec(title);
  397.          }
  398.  
  399.          if(desc)
  400.          {
  401.            printf("%s\n");
  402.            FreeVec(desc);
  403.          }
  404.        }
  405.  
  406.  
  407.    NOTES
  408.        The database file format is an ASCII text file, and consists
  409.        of "ENTRY"'s, that look like this:
  410.  
  411.        <ENTRYNAME>
  412.        {
  413.          <ITEMNAME> = <data>
  414.          <ITEMNAME> = <data>
  415.        }
  416.  
  417.        an example file format from above might be:
  418.  
  419.        ENTRY
  420.        {
  421.          TITLE=Cows 'R Us
  422.          DESC=All you want to know about beef.
  423.        }
  424.  
  425.        case of <ENTRYNAME> and <ITEMNAMES> is not important.
  426.        the equal sign is required.
  427.        
  428.    HISTORY
  429.        This code probably isn't all that usefull, but it was the
  430.        code behind the database of now defunct Tampa Bay Amiga Group's
  431.        Amiga Support Directory.  Unfortunately, TBAG died before the
  432.        ASD could begine to grow, and I haven't used this code since.
  433.  
  434.    BUGS
  435.        Not reentrant.
  436.  
  437.    SEE ALSO
  438.        nns_ProcessNNStr, nns_AddNNStr(), nns_NextNNStr(), db_EntryToNN()
  439.  
  440. extras.lib/db_NextEntry                               extras.lib/db_NextEntry
  441.  
  442.    NAME
  443.        db_NextEntry - Find the next entry in a database file.
  444.  
  445.    SYNOPSIS
  446.        error = db_NextEntry(File, EntryName, Buffer, BufferSize)
  447.        
  448.        LONG db_NextEntry(BPTR, STRPTR, STRPTR, ULONG);
  449.  
  450.    FUNCTION
  451.        Seeks for the next entry in a database file.
  452.  
  453.    INPUTS
  454.        File - AmigaDos file handle.
  455.        EntryName - the name of the entry, usually "ENTRY".
  456.               case is insignificant.
  457.        Buffer - a buffer for reading data from a file.
  458.        BufferSize - the size of the buffer.
  459.  
  460.    RESULT
  461.        returns 0 on failure.  on success the file is positioned
  462.        inside the entry.
  463.  
  464.    EXAMPLE
  465.  
  466.    NOTES
  467.        This function is mainly used for other lib functions
  468.  
  469.    BUGS
  470.  
  471.    SEE ALSO
  472.  
  473. extras.lib/EnqueueName                                 extras.lib/EnqueueName
  474.  
  475.    NAME
  476.        EnqueueName -- Place a Node in a sorted List.
  477.  
  478.    SYNOPSIS
  479.        EnqueueName(List,Node)
  480.  
  481.        void EnqueueName(struct List *,struct Node*)
  482.  
  483.    FUNCTION
  484.        Place a Node in a sorted List prioritized by Node.ln_Name 
  485.        and ln_Pri.
  486.  
  487.    INPUTS
  488.        List - pointer to a List to place Node into.
  489.        Node - pointer to a Node to be placed in the List.
  490.  
  491.    RESULT
  492.        None.
  493.  
  494.    NOTES
  495.        The List must be presorted by ln_Name and ln_Pri.
  496.        Every node must have its ln_Name field pointing to
  497.        a NULL terminated string.
  498.  
  499. extras.lib/ex_CloseLibs                               extras.lib/ex_CloseLibs
  500.  
  501.    NAME
  502.        ex_CloseLibs -- close multiple libraries.
  503.  
  504.    SYNOPSIS
  505.        ex_CloseLibs(Libs)
  506.  
  507.        void ex_CloseLibs(struct Libs *);
  508.  
  509.    FUNCTION
  510.        Close multiple libraries using the same array of
  511.        struct Libs as used in OpenLibs.
  512.  
  513.    INPUTS
  514.        Libs - A pointer to an array of struct Libs.
  515.  
  516.    RESULT
  517.        none.
  518.  
  519.    NOTES
  520.        exec.library must already be opened.(usually done by the 
  521.        compiler's startup code)
  522.  
  523.        revision 1.1
  524.          corrected autodoc.
  525.          now openes ExecBase on it's own.
  526.        revision 1.2
  527.          renamed to ex_CloseLib due to conflict with reaction.lib
  528.  
  529.    BUGS
  530.  
  531.    SEE ALSO
  532.        ex_OpenLibs()
  533. extras.lib/ex_OpenLibs                                 extras.lib/ex_OpenLibs
  534.  
  535.    NAME
  536.        ex_OpenLibs -- attempt to open multiple libraries.
  537.  
  538.    SYNOPSIS
  539.        success = ex_OpenLibs(Argc,ProgName,ErrorStr,
  540.                    LibVerFmt,ButtonText,Libs)
  541.  
  542.        BOOL ex_OpenLibs(ULONG Argc, STRPTR ProgName, STRPTR ErrorString, 
  543.               STRPTR LibVerFmt, STRPTR ButtonText, struct Libs *Libs);
  544.  
  545.    FUNCTION
  546.        Attempt to open multiple Libraries.  If any library
  547.        fails to open, a requester is opened to notify the 
  548.        user listing all of the libraries that failed to open. 
  549.  
  550.    INPUTS
  551.        Argc       - argc from main()
  552.        ProgName   - pointer to a string containing the 
  553.                    program's name.
  554.        ErrorStr   - error string.  May be NULL.  Defaults to
  555.                    "The following libraries are required:\n";
  556.        LibVerFmt  - printf style format string.  Defaults to 
  557.                     "  %s version %ld\n"
  558.        ButtonText - If a requester is used to display an error
  559.                     message, this text is used in the button.
  560.                     Defaults to "Ok"
  561.        Libs       - an array of libraries to open.
  562.  
  563.    RESULT
  564.        return 0 on failure and non-zero on success.
  565.  
  566.    EXAMPLE
  567.        struct IntuitionBase *IntuitionBase;
  568.        struct GfxBase *GfxBase;
  569.        struct Library *GadToolsBase;
  570.        
  571.        struct Libs MyLibs[]=
  572.        {
  573.          &IntuitionBase,"intuition.library"    ,37, 0,
  574.          &GfxBase      ,"graphics.library"     ,37, 0,
  575.          &GadToolsBase ,"gadtools.library"     ,37, 0,
  576.          &LocaleBase   ,"datatypes.library"    ,39, OLF_OPTIONAL,
  577.          0,0,0
  578.        };
  579.  
  580.        void main(int argc, char **argv) 
  581.        {
  582.          if(ex_OpenLibs(arcg,"MyProgram",0,0,0,MyLibs))
  583.          {
  584.            ...
  585.            CloseLibs(MyLibs);
  586.          }
  587.        }
  588.  
  589.    NOTES
  590.        On error, this function will automatically display an 
  591.        intuition requester if Argc=0 or print error information 
  592.        out to STDIO if Argc>0.
  593.  
  594.        exec.library must already be open.(usually done by the 
  595.        compiler's startup code)
  596.  
  597.        revision 1.1
  598.          autodoc fix
  599.          now opens exec.library on it's own.
  600.        revision 1.2
  601.          renamed to ex_OpenLib due to conflict with reaction.lib
  602.  
  603.        
  604.  
  605.    BUGS
  606.  
  607.    SEE ALSO
  608.        ex_CloseLibs()
  609. extras.lib/EZReq                                             extras.lib/EZReq
  610.  
  611.    NAME
  612.        EZReq -- create an Intuition EasyRequest.
  613.  
  614.    SYNOPSIS
  615.        retval = EZReq(Win, IDCMP_ptr, Title, Text,
  616.                        ButtonText,Arg,...)
  617.  
  618.        LONG EZReq(struct Window *, ULONG *, STRPTR, STRPTR, 
  619.                   STRPTR, ULONG, ...);
  620.  
  621.    FUNCTION
  622.        This function provides an easier method to use the 
  623.        intuition/EasyRequestArgs() function.
  624.  
  625.    INPUTS
  626.        Win -
  627.        IDCMP_ptr - 
  628.        Title -
  629.        Text -
  630.        ButtonText -
  631.        Arg -
  632.  
  633.    RESULT
  634.  
  635.    EXAMPLE
  636.  
  637.    NOTES
  638.        requires the exec.library to be open, automatically opens
  639.        intuition.library.
  640.  
  641.    BUGS
  642.  
  643.    SEE ALSO
  644.  
  645. extras.lib/FindLine                                       extras.lib/FindLine
  646.  
  647.    NAME
  648.        FindLine - find the next matching line in a file.
  649.  
  650.    SYNOPSIS
  651.  
  652.  
  653.  
  654.  
  655.  
  656.  
  657.    FUNCTION
  658.  
  659.  
  660.    INPUTS
  661.  
  662.    RESULT
  663.  
  664.    EXAMPLE
  665.  
  666.    NOTES
  667.  
  668.    BUGS
  669.  
  670.    SEE ALSO
  671.  
  672. extras.lib/FreeProgressMeter                     extras.lib/FreeProgressMeter
  673.  
  674.    NAME
  675.        FreeProgressMeter -- Close a PregressMeter.
  676.  
  677.    SYNOPSIS
  678.        FreeProgressMeter(PM)
  679.  
  680.        void FreeProgressMeter(ProgressMeter );
  681.  
  682.    FUNCTION
  683.        Close and deallocated a ProgressMeter.
  684.  
  685.    INPUTS
  686.        PM - pointer to an existing ProgressMeter or NULL.
  687.  
  688.    RESULT
  689.        none.
  690.  
  691.    EXAMPLE
  692.  
  693.    NOTES
  694.      requires diskfont, exec, gadtools, graphics, intuition & utility
  695.      libraries to be open.
  696.  
  697.    BUGS
  698.  
  699.    SEE ALSO
  700.        AllocProgressMeterA(), UpdateProgressMeterA()
  701.  
  702. extras.lib/ftos                                               extras.lib/ftos
  703.  
  704.    NAME
  705.        ftos - Convert a float to a string
  706.  
  707.    SYNOPSIS
  708.  
  709.  
  710.  
  711.  
  712.  
  713.  
  714.    FUNCTION
  715.  
  716.  
  717.    INPUTS
  718.  
  719.    RESULT
  720.  
  721.    EXAMPLE
  722.  
  723.    NOTES
  724.  
  725.    BUGS
  726.  
  727.    SEE ALSO
  728.  
  729. extras.lib/gui_GhostRect                             extras.lib/gui_GhostRect
  730.  
  731.    NAME
  732.        GhostRect -- Cover a rectangular are with 
  733.                     a ghosted pattern.
  734.  
  735.    SYNOPSIS
  736.        gui_GhostRect(RP, Pen, X0, Y0, X1, Y1)
  737.  
  738.        void gui_GhostRect(struct RastPort *, ULONG, 
  739.             WORD, WORD, WORD, WORD); 
  740.  
  741.    FUNCTION
  742.        Covers a rectangular area with a ghosted pattern
  743.        using the specified pen number.
  744.  
  745.    INPUTS
  746.        RP - Pointer to a RastPort.
  747.        Pen - the pen number to use for the pattern.
  748.        X0 - left edge 
  749.        Y0 - top edge
  750.        X1 - right edge
  751.        Y1 - bottom edge
  752.  
  753. extras.lib/gui_MaxStrFontLen                     extras.lib/gui_MaxStrFontLen
  754.  
  755.    NAME
  756.        gui_MaxStrFontLen - get the maximum pixel length of a
  757.        string containg N characters. 
  758.  
  759.    SYNOPSIS
  760.        length=gui_MaxStrFontLen(Font, Chars, LowChar, HighChar)
  761.  
  762.        LONG gui_MaxStrFontLen(struct TextFont *, ULONG, UBYTE, UBYTE);
  763.  
  764.    FUNCTION
  765.        This function returns the maximum number of pixels
  766.        a string with a certain number of characters could
  767.        occupy.
  768.  
  769.    INPUTS
  770.        Font - struct TextFont * previously opened by 
  771.               OpenFont() or OpenDiskFont().
  772.        Chars - the max number characters in a string.
  773.        LowChar - the ASCII number of lowest character
  774.                  that could be in a string.
  775.        HighChar - the ASCII number of the highest character
  776.                   that could be in a string.
  777.  
  778.    EXAMPLE
  779.         find the longest pixel length of a number 
  780.         upto 3 digits 
  781.        long maxnumberlen;
  782.        struct TextFont *tf;
  783.  
  784.        maxnumberlen=gui_MaxStrFontLen(tf,3,'0','9');
  785.  
  786.    RESULT
  787.        the pixel length or 0 if the Font parameter
  788.        is NULL.
  789.  
  790. extras.lib/gui_StrFontLen                           extras.lib/gui_StrFontLen
  791.  
  792.    NAME
  793.        gui_StrFontLen - get the pixel length of a string.
  794.  
  795.    SYNOPSIS
  796.        length=gui_StrFontLen(Font, Str)
  797.  
  798.        LONG gui_StrFontLen(struct TextFont *,STRPTR);
  799.  
  800.    FUNCTION
  801.        This function returns the number of pixels a string
  802.        would occupy if rendered in the specified Font.
  803.  
  804.    INPUTS
  805.        Font - struct TextFont * previously opened by 
  806.               OpenFont() or OpenDiskFont().
  807.        Str - a pointer to a null terminated string.
  808.  
  809.    RESULT
  810.        the pixel length of the string or 0 if either parameter
  811.        is NULL.
  812.  
  813. extras.lib/gui_StrLength                             extras.lib/gui_StrLength
  814.  
  815.    NAME
  816.        gui_StrLength -- Get the pixel length of a string.
  817.  
  818.    SYNOPSIS
  819.        Len = gui_StrLength(Tags)
  820.        
  821.        LONG gui_StrLength(Tag, ... );
  822.  
  823.    FUNCTION
  824.        Find the length of a given string.  If multiple strings
  825.        are given, returns the longest length.
  826.  
  827.    INPUTS
  828.        Tags 
  829.          SL_TextFont - (struct TextFont *)The font the string will
  830.            be rendered in. (required)
  831.          SL_IgnoreChars - (STRPTR) Null terminated string of characters
  832.            to ignore from the length calculation, useful for underscores
  833.            in gadget text, etc.
  834.          SL_String - (STRPTR) String to size.
  835.  
  836.    RESULT
  837.        Length in pixels of longest string.
  838.  
  839.    EXAMPLE
  840.          *find length of button text without the "_" 
  841.          len= gui_StrLength(SL_TextFont     ,TF,
  842.                         SL_String       ,"_Button",
  843.                         SL_IgnoreChars  ,"_",
  844.                         TAG_DONE);
  845.  
  846.          * find maximum length of red, green and blue without "_"
  847.          len= gui_StrLength(SL_TextFont     ,TF,
  848.                         SL_String       ,"_Red",
  849.                         SL_String       ,"_Green",
  850.                         SL_String       ,"_Blue",
  851.                         SL_IgnoreChars  ,"_",
  852.                         TAG_DONE);
  853.  
  854.    NOTES
  855.  
  856.    BUGS
  857.  
  858.    SEE ALSO
  859.  
  860. extras.lib/IsWhiteSpace                               extras.lib/IsWhiteSpace
  861.  
  862.    NAME
  863.        IsWhiteSpace -- Is a character a "white-space"
  864.  
  865.    SYNOPSIS
  866.        IsWhiteSpace(Char)
  867.  
  868.        BOOL IsWhiteSpace(char);
  869.  
  870.    FUNCTION
  871.        Indicate whether or not a character is a "white-space"
  872.  
  873.    INPUTS
  874.        Char - a letter.
  875.  
  876.    RESULT
  877.        non-0 if Char is " "(space), "\t"(tab), or "\n"(cr)
  878.  
  879.    EXAMPLE
  880.  
  881.    NOTES
  882.  
  883.    BUGS
  884.  
  885.    SEE ALSO
  886.  
  887. extras.lib/key_Shifted                                 extras.lib/key_Shifted
  888.  
  889.    NAME
  890.        key_Shifted -- Get shifted character of suppied character
  891.  
  892.    SYNOPSIS
  893.        shiftedchar = key_Shifted(character)
  894.  
  895.        ULONG key_Shifted(char);
  896.  
  897.    FUNCTION
  898.        Returns the shifted character for the supplied character.
  899.        For example (on the USA keymap) 
  900.          key_Shifted('#') = '#' 
  901.          key_Shifted('3') = '#'
  902.  
  903.    NOTE
  904.        This function was previously KeyShifted()
  905.  
  906.    SEE ALSO
  907.        Key_Unshifted()
  908.  
  909. extras.lib/key_Unshifted                             extras.lib/key_Unshifted
  910.  
  911.    NAME
  912.        key_Unshifted -- Get unshifted character of suppied character
  913.  
  914.    SYNOPSIS
  915.        unshiftedchar = key_Unshifted(character)
  916.  
  917.        ULONG key_Unshifted(char);
  918.  
  919.    FUNCTION
  920.        Returns the unshifted character for the supplied character.
  921.        For example (on the USA keymap) 
  922.          key_Unshifted('#') = '3' 
  923.          key_Unshifted('3') = '3'
  924.  
  925.    NOTE
  926.        This function was previously KeyUnshifted()
  927.  
  928.    SEE ALSO
  929.        KeyShifted()
  930.  
  931. extras.lib/MultiAllocMemA                           extras.lib/MultiAllocMemA
  932.  
  933.    NAME
  934.        MultiAllocMemA -- Multiple AllocMem.
  935.        MultiAllocMem -- varargs stub.
  936.  
  937.    SYNOPSIS
  938.        succes = MultiAllocMemA(Flags, MemTagList)
  939.  
  940.        BOOL MultiAllocMem(ULONG, struct MemTag *);
  941.  
  942.        succes = MultiAllocMemA(Flags, MemTag)
  943.  
  944.        BOOL MultiAllocMemA(Flags, ULONG, ...);
  945.  
  946.    FUNCTION
  947.        Attempt to allocate one or more memory chunks
  948.        using AllocMem.
  949.  
  950.    INPUTS
  951.        Flags - MA_FAILSIZE0: fail all allocations if any
  952.                have a size of 0.  if your application will be
  953.                allocating memory of dynamic sizes, and if
  954.                you want allocations of 0 bytes to fail, then
  955.                set this flag.
  956.        MemTag - pointer to an array of struct MemTag.
  957.                   vt_Ptr is the address of a pointer.
  958.                   vt_Size is the size of the allocation.
  959.                   vt_MemFlags are the exec memory (MEMF_) flags. 
  960.                 Last tag should have vt_Ptr = NULL.
  961.                  
  962.    RESULT
  963.        zero if it couldn't allocate the requested memory. or non-zero
  964.        on success. vt_Ptrs will be point to a allocated 
  965.        memory chunk or NULL.  
  966.  
  967.    EXAMPLE
  968.        EX1:
  969.          struct foo *bar;
  970.          STRPTR dest;
  971.          APTR cow;
  972.  
  973.         if( MultiAllocMem(0,
  974.                            &bar,  sizeof(struct foo),  MEMF_CLEAR,
  975.                            &dest, 25,                  MEMF_PUBLIC,
  976.                            &cow,  100,                 MEMF_FAST|MEMF_PUBLIC,
  977.                            0))
  978.          {
  979.            ...
  980.            MultiFreeMem(3,
  981.                            bar  ,sizeof(struct foo),
  982.                            dest ,25,
  983.                            cow  ,100);
  984.          }
  985.  
  986.        EX2: This will never fail.
  987.          APTR foo;
  988.          if(MultiAllocMem(0,
  989.                            &foo,0,MEMF_CLEAR,
  990.                            0)
  991.          {...}
  992.  
  993.        EX3: This will always fail.
  994.          APTR foo;
  995.          if(MultiAllocMem(MA_FAILSIZE0,
  996.                            &foo,0,MEMF_CLEAR,
  997.                            0)
  998.          {...}
  999.  
  1000.    NOTES
  1001.        requires exec.library to be open.
  1002.  
  1003.        if the MA_FAILSIZE0 Flag is not set, 0 byte allocations
  1004.        will pass even though no memory will be allocated for that.
  1005.        entry and mt_Ptr will be set to 0.
  1006.  
  1007.        The memory allocated may be freed individually with 
  1008.        exec.library/FreeMem()
  1009.  
  1010.    BUGS
  1011.  
  1012.    SEE ALSO
  1013.        MultiAllocVecA(), MultiFreeVecA(), MultiFreeMemA(),
  1014.        MultiAllocPooledA(), MultiFreePooledA(),
  1015.        exec.library/AllocVec(), exec.library/FreeVec()
  1016.        exec.library/AllocMem(), exec.library/FreeMem()
  1017.        exec.library/AllocPooled(), exec.library/FreePooled()
  1018. extras.lib/MultiAllocPooledA                     extras.lib/MultiAllocPooledA
  1019.  
  1020.    NAME
  1021.        MultiAllocPooledA -- Multiple AllocPooled.
  1022.        MultiAllocPooled -- varargs stub.
  1023.  
  1024.    SYNOPSIS
  1025.        succes = MultiAllocPooledA(Flags, PoolTagList)
  1026.  
  1027.        BOOL MultiAllocPooled(ULONG, struct PoolTag*);
  1028.  
  1029.        succes = MultiAllocPooledA(Flags, PoolTag)
  1030.  
  1031.        BOOL MultiAllocPooledA(Flags, ULONG, ...);
  1032.  
  1033.    FUNCTION
  1034.        Attempt to allocate one or more memory chunks
  1035.        using AllocPooled.
  1036.  
  1037.    INPUTS
  1038.        Flags - MA_FAILSIZE0: fail all allocations if any
  1039.                have a size of 0.  if your application will be
  1040.                allocating memory of dynamic sizes, and if
  1041.                you want allocations of 0 bytes to fail, then
  1042.                set this flag.
  1043.        PoolTag - pointer to an array of struct PoolTag.
  1044.                   pt_Ptr is the address of a pointer.
  1045.                   pt_Size is the size of the allocation.
  1046.                 Last tag should have vt_Ptr = NULL.
  1047.                  
  1048.    RESULT
  1049.        zero if it couldn't allocate the requested memory. or non-zero
  1050.        on success. In either case, vt_Ptrs will be point to a allocated 
  1051.        memory chunk or NULL.  
  1052.  
  1053.    EXAMPLE
  1054.        EX1:
  1055.          APTR pool;
  1056.          struct foo *bar;
  1057.          STRPTR dest;
  1058.          APTR cow;
  1059.  
  1060.          if(pool=CreatePool(MEMF_ANY,300,300))
  1061.          {
  1062.            if( MultiAllocPooled(pool,0,
  1063.                            &bar,  sizeof(struct foo),
  1064.                            &dest, 50,       
  1065.                            &cow,  100,
  1066.                            0))
  1067.            {
  1068.              ...
  1069.              MultiFreePooled(pool,3,
  1070.                                bar,  sizeof(struct foo),
  1071.                                dest, 50,
  1072.                                cow,  100);
  1073.            }
  1074.            DeletePool(pool);
  1075.          }
  1076.  
  1077.        EX2: This will never fail.
  1078.          if(MultiAllocPooled(pool,0,
  1079.                            &foo, 0,
  1080.                            0)
  1081.          {...}
  1082.  
  1083.        EX3: This will always fail.
  1084.          if(MultiAllocPooled(pool,MA_FAILSIZE0,
  1085.                            &foo, 0,
  1086.                            0)
  1087.          {...}
  1088.  
  1089.    NOTES
  1090.        requires exec.library to be open.
  1091.  
  1092.        if the MA_FAILSIZE0 flag is not set, 0 byte allocations
  1093.        will pass even though no memory will be allocated for that.
  1094.        entry and mt_Ptr will be set to 0.
  1095.  
  1096.        The memory allocated may be freed individually with 
  1097.        exec.library/FreePooled()
  1098.  
  1099.    BUGS
  1100.  
  1101.    SEE ALSO
  1102.        MultiFreeVecA(), MultiAllocMemA(),MultiFreeMemA(),
  1103.        MultiFreePooledA(),
  1104.        exec.library/AllocVec(), exec.library/FreeVec()
  1105.        exec.library/AllocMem(), exec.library/FreeMem()
  1106.        exec.library/AllocPooled(), exec.library/FreePooled()
  1107. extras.lib/MultiAllocVecA                           extras.lib/MultiAllocVecA
  1108.  
  1109.    NAME
  1110.        MultiAllocVecA -- Multiple AllocVec.
  1111.        MultiAllocVec -- varargs stub.
  1112.  
  1113.    SYNOPSIS
  1114.        succes = MultiAllocVecA(Flags, VecTagList)
  1115.  
  1116.        BOOL MultiAllocVec(ULONG, struct VecTag *);
  1117.  
  1118.        succes = MultiAllocVecA(Flags, VecTag)
  1119.  
  1120.        BOOL MultiAllocVecA(Flags, ULONG, ...);
  1121.  
  1122.    FUNCTION
  1123.        Attempt to allocate one or more memory chunks
  1124.        using AllocVec.
  1125.  
  1126.    INPUTS
  1127.        Flags - MA_FAILSIZE0: fail all allocations if any
  1128.                have a size of 0.  if your application will be
  1129.                allocating memory of dynamic sizes, and if
  1130.                you want allocations of 0 bytes to fail, then
  1131.                set this flag.
  1132.        VecTag - pointer to an array of struct VecTag.
  1133.                   vt_Ptr is the address of a pointer.
  1134.                   vt_Size is the size of the allocation.
  1135.                   vt_MemFlags are the exec memory (MEMF_) flags. 
  1136.                 Last tag should have vt_Ptr = NULL.
  1137.                  
  1138.    RESULT
  1139.        zero if it couldn't allocate the requested memory. or non-zero
  1140.        on success. In either case, vt_Ptrs will be point to a allocated 
  1141.        memory chunk or NULL.  
  1142.  
  1143.    EXAMPLE
  1144.        EX1:
  1145.          struct foo *bar;
  1146.          STRPTR dest;
  1147.          APTR cow;
  1148.  
  1149.         if( MultiAllocVec(0,
  1150.                            &bar,  sizeof(struct foo),  MEMF_CLEAR,
  1151.                            &dest, strlen(str)+1,       MEMF_PUBLIC,
  1152.                            &cow,  100,                 MEMF_FAST|MEMF_PUBLIC,
  1153.                            0))
  1154.          {
  1155.            ...
  1156.            MultiFreeVec(3,bar,dest,cow);
  1157.          }
  1158.  
  1159.        EX2: This will never fail.
  1160.          APTR foo;
  1161.          if(MultiAllocVec(0,
  1162.                            &foo,0,MEMF_CLEAR,
  1163.                            0)
  1164.          {...}
  1165.  
  1166.        EX3: This will always fail.
  1167.          APTR foo;
  1168.          if(MultiAllocVec(MA_FAILSIZE0,
  1169.                            &foo,0,MEMF_CLEAR,
  1170.                            0)
  1171.          {...}
  1172.  
  1173.    NOTES
  1174.        requires exec.library to be open.
  1175.  
  1176.        if the MA_FAILSIZE0 flag is not set, 0 byte allocations
  1177.        will pass even though no memory will be allocated for that.
  1178.        entry and mt_Ptr will be set to 0.
  1179.  
  1180.        The memory allocated may be freed individually with 
  1181.        exec.library/FreeVec()
  1182.  
  1183.    BUGS
  1184.  
  1185.    SEE ALSO
  1186.        MultiFreeVecA(), MultiAllocMemA(),MultiFreeMemA(),
  1187.        MultiAllocPooledA(),MultiFreePooledA(),
  1188.        exec.library/AllocVec(), exec.library/FreeVec()
  1189.        exec.library/AllocMem(), exec.library/FreeMem()
  1190.        exec.library/AllocPooled(), exec.library/FreePooled()
  1191. extras.lib/MultiFreeMemA                             extras.lib/MultiFreeMemA
  1192.  
  1193.    NAME
  1194.        MultiFreeMemA -- Free multiple memory chunks.
  1195.        MultiFreeMem -- varargs stub.
  1196.  
  1197.    SYNOPSIS
  1198.        MultiFreeMemA(Args, FreeTagList)
  1199.  
  1200.        void MultiFreeMemA(ULONG, struct FreeTag *);
  1201.  
  1202.        MultiFreeMem(Args, FreeTag, ... )
  1203.  
  1204.        void MultiFreeMem(ULONG, ULONG, ... );
  1205.  
  1206.    FUNCTION
  1207.        Free multiple memory blocks allocated with MultiAllocMemA()
  1208.        or exec.library/AllocMem(). 
  1209.  
  1210.    INPUTS
  1211.        Args - Number of blocks that are to be freed.
  1212.        FreeTagList - An array of FreeTags. may be NULL.
  1213.                        ft_Ptr - contains a pointer to a
  1214.                                 memory block or NULL.
  1215.                        ft_Size - the size of the block.
  1216.  
  1217.    RESULT
  1218.        none.
  1219.  
  1220.    NOTES
  1221.        requires exec.library to be open.
  1222.  
  1223.    SEE ALSO
  1224.        MultiAllocVecA(), MultiFreeVecA(), MultiAllocMemA(),
  1225.        MultiAllocPooledA(), MultiFreePooledA(),
  1226.        exec.library/AllocVec(), exec.library/FreeVec()
  1227.        exec.library/AllocMem(), exec.library/FreeMem()
  1228.        exec.library/AllocPooled(), exec.library/FreePooled()
  1229.  
  1230. extras.lib/MultiFreePooledA                       extras.lib/MultiFreePooledA
  1231.  
  1232.    NAME
  1233.        MultiFreePooledA -- Free multiple memory chunks.
  1234.        MultiFreePooled -- varargs stub.
  1235.  
  1236.    SYNOPSIS
  1237.        MultiFreePooledA(Pool, Args, FreeTagList)
  1238.  
  1239.        void MultiFreePooledA(APTR, ULONG, struct FreeTag *);
  1240.  
  1241.        MultiFreePooled(Pool, Args, FreeTag, ... )
  1242.  
  1243.        void MultiFreePooled(APTR, ULONG, ULONG, ... );
  1244.  
  1245.    FUNCTION
  1246.        Free multiple memory blocks allocated with MultiAllocPooledA()
  1247.        or exec.library/AllocPooled(). 
  1248.  
  1249.    INPUTS
  1250.        Args - Number of blocks that are to be freed.
  1251.        FreeTagList - An array of FreeTags. may be NULL.
  1252.                        ft_Ptr - contains a pointer to a
  1253.                                 memory block or NULL.
  1254.                        ft_Size - the size of the block.
  1255.  
  1256.    RESULT
  1257.        none.
  1258.  
  1259.    NOTES
  1260.        requires exec.library to be open.
  1261.  
  1262.    SEE ALSO
  1263.        MultiAllocVecA(), MultiFreeVecA(), MultiAllocMemA(),
  1264.        MultiAllocPooledA(), MultiFreePooledA(),
  1265.        exec.library/AllocVec(), exec.library/FreeVec()
  1266.        exec.library/AllocMem(), exec.library/FreeMem()
  1267.        exec.library/AllocPooled(), exec.library/FreePooled()
  1268.  
  1269. extras.lib/MultiFreeVecA                             extras.lib/MultiFreeVecA
  1270.  
  1271.    NAME
  1272.        MultiFreeVecA -- Free multiple memory chunks.
  1273.        MultiFreeVec -- varargs stub.
  1274.  
  1275.    SYNOPSIS
  1276.        MultiFreeVecA(Args,MemBlockList)
  1277.  
  1278.        MultiFreeVecA(ULONG, APTR *);
  1279.  
  1280.        MultiFreeVec(Args, MemBlock)
  1281.  
  1282.        void MultiFreeVec(ULONG, ULONG, ... );
  1283.  
  1284.    FUNCTION
  1285.        Free multiple memory blocks allocated with MultiAllocVecA()
  1286.        or exec.library/AllocVec(). 
  1287.  
  1288.    INPUTS
  1289.        Args - Number of blocks that are to be freed.
  1290.        MemBlockList - An array of pointers to memory
  1291.                       blocks to be freed or NULL.
  1292.  
  1293.    RESULT
  1294.        none.
  1295.  
  1296.    NOTES
  1297.        requires exec.library to be open.
  1298.  
  1299.    SEE ALSO
  1300.        MultiAllocVecA(), MultiFreeVecA(), MultiAllocMemA(), MultiFreeMemA(),
  1301.        MultiAllocPooledA(), MultiFreePooledA(),
  1302.        exec.library/AllocVec(), exec.library/FreeVec()
  1303.        exec.library/AllocMem(), exec.library/FreeMem()
  1304.        exec.library/AllocPooled(), exec.library/FreePooled()
  1305. extras.lib/NextNNStr                                     extras.lib/NextNNStr
  1306.  
  1307.    NAME
  1308.        NextNNStr -- Get the next string in a double NULL terminted
  1309.                     string array (aka NNString).
  1310.  
  1311.    SYNOPSIS
  1312.        nextstring=NextNNStr(NNString)
  1313.  
  1314.        STRPTR NextNNStr(STRPTR);
  1315.  
  1316.    FUNCTION
  1317.        returns a pointer to the next string contained in a 
  1318.        double NULL teminated string array, or NULL.
  1319.  
  1320.    INPUTS
  1321.        NNString - A pointer to some part of a double NULL string.
  1322.  
  1323.    RESULT
  1324.        Pointer to the next string or NULL if there is no string.
  1325.  
  1326.    EXAMPLE
  1327.        ** this example steps through an NNString. **
  1328.  
  1329.        STRPTR NNString;
  1330.        STRPTR str;
  1331.  
  1332.        for(str=NNString; str; str=NextNNStr(str))
  1333.        {
  1334.          printf("%s\n",str);
  1335.        }
  1336.  
  1337.        The above can be simplified by using the ProcessNNStr macro
  1338.        defined in extras/nnstring.h
  1339.  
  1340.        STRPTR NNString;
  1341.        STRPTR str;
  1342.  
  1343.        ProcessNNStr(NNString,str)
  1344.        {
  1345.          printf("%s\n",str);
  1346.        }
  1347.  
  1348.    NOTES
  1349.  
  1350.    BUGS
  1351.  
  1352.    SEE ALSO
  1353.        NNString AddNNStr() ProcessNNStr, extras/macros.h
  1354.  
  1355. extras.lib/nns_AddNNStr                               extras.lib/nns_AddNNStr
  1356.  
  1357.    NAME
  1358.        nns_AddNNStr -- append a normal string to a NNString.
  1359.  
  1360.    SYNOPSIS
  1361.        NewNNStr=nns_AddNNStr(NNStr,New)
  1362.  
  1363.        STRPTR nns_AddNNStr(STRPTR, STRPTR);
  1364.  
  1365.    FUNCTION
  1366.        
  1367.  
  1368.    INPUTS
  1369.        NNStr - an existing NNString or NULL, if NULL
  1370.            the function converts str into an NNString.
  1371.        New - a regular NULL terminated string.
  1372.  
  1373.    RESULT
  1374.        A new NNString or NULL, NNStr *WILL* be freed
  1375.        regardless of result.  if New is NULL, NNStr will
  1376.        be returned.
  1377.  
  1378.    EXAMPLE
  1379.  
  1380.    NOTES
  1381.  
  1382.    BUGS
  1383.  
  1384.    SEE ALSO
  1385.  
  1386. extras.lib/nns_GetNNData                             extras.lib/nns_GetNNData
  1387.  
  1388.    NAME
  1389.        nns_GetNNData -- Find data in a NNString
  1390.  
  1391.    SYNOPSIS
  1392.        STRPTR GetNNData(STRPTR NNStr, STRPTR Name, STRPTR DefVal);
  1393.  
  1394.    FUNCTION
  1395.        Retrieves data from a NNString.
  1396.  
  1397.        nnstr="TITLE=Joe\0COLOR=Green\0TITLE=Test\0\0"
  1398.  
  1399.        t=GetNNData(nnstr,"TITLE","None");
  1400.  
  1401.        t will equal "Joe\0Test\0\0"
  1402.  
  1403.    SEE ALSO
  1404.  
  1405. extras.lib/nns_NNStrLen                               extras.lib/nns_NNStrLen
  1406.  
  1407.    NAME
  1408.        nns_NNStrLen -- Return the length of an NNString.
  1409.  
  1410.    SYNOPSIS
  1411.        length=nns_NNStrLen(NNStr)
  1412.  
  1413.        LONG nns_NNStrLen(STRPTR);
  1414.  
  1415.    FUNCTION
  1416.        Returns the length in bytes of an NNString, including the
  1417.        trailing NULLs. 
  1418.  
  1419.    INPUTS
  1420.        NNStr - NNString pointer.
  1421.  
  1422.    RESULT
  1423.        Size of NNStr include NULLs.
  1424.  
  1425.    SEE ALSO
  1426.  
  1427. extras.lib/NNString_Overview                     extras.lib/NNString_Overview
  1428.  
  1429.    FUNCTION
  1430.        An NNString is an array of strings, stored end to end, ending
  1431.        with a double NULL.  Individual strings are seperated by NULLs.
  1432.  
  1433.    EXAMPLE
  1434.        An NNString representing this array of strings:
  1435.        "Cow" "Dog" "Barn"
  1436.        would look like this:
  1437.        "Cow\0Dog\0Barn\0\0"
  1438.  
  1439.    SEE ALSO
  1440.        NextNNStr(), ProcessNNStr, GetEntryData(), AddNNStr(), 
  1441.        NNStrLen()
  1442.  
  1443. extras.lib/NotBusy                                         extras.lib/NotBusy
  1444.  
  1445.    NAME
  1446.        NotBusy -- displays busy pointer.
  1447.  
  1448.    SYNOPSIS
  1449.        NotBusy(Window)
  1450.  
  1451.        void NotBusy(struct Window *);
  1452.  
  1453.    FUNCTION
  1454.        Removes the busy pointer for the specified
  1455.        window.
  1456.  
  1457.    INPUTS
  1458.        Window - the window to remove the busy pointer
  1459.                 from.
  1460.  
  1461.    RESULT
  1462.        None.
  1463.  
  1464.    NOTES
  1465.        requires intuition.library to be open.
  1466.  
  1467.        This does not change the Window's IDCMP flags.
  1468.        This function does nothing in WB versions less than
  1469.        3.0
  1470.  
  1471.    SEE ALSO
  1472.        Busy()
  1473.  
  1474. extras.lib/OBSOLETE--datasheet--             extras.lib/OBSOLETE--datasheet--
  1475.  
  1476.    NOTES
  1477.        I deem some functions obsolete.
  1478.  
  1479.        All the GadTools layout code and support Functions are obsolete,
  1480.        due to OS3.5 being released with Reaction/ClassAct. 
  1481.  
  1482.        I found it easier to convert a gui than to maintain it with my code :)
  1483.        They remain in the archive and in the .lib's only because some program
  1484. s
  1485.        still need them to compile.
  1486.  
  1487. extras.lib/OBSOLETE_CheckInnerWindowSizeras.lib/OBSOLETE_CheckInnerWindowSize
  1488.  
  1489.    OBSOLETE
  1490.        Since OS3.5 uses Reaction/ClassAct - this code is obsolete
  1491.  
  1492.    NAME
  1493.        CheckInnerWindowSize - See if a window will fit on a screen.
  1494.  
  1495.    SYNOPSIS
  1496.        windowfits = CheckInnerWindowSize(Scr, Width, Height,
  1497.                                      XScale, YScale)
  1498.  
  1499.        BOOL CheckInnerWindoeSize(struct Screen *, WORD, WORD, 
  1500.                                     float, float);
  1501.  
  1502.    FUNCTION
  1503.        This function checks to see if a window with the specified
  1504.        inner dimensions will fit on a screen.
  1505.  
  1506.    INPUTS
  1507.        Scr - the Screen the window is destine for.
  1508.        Width -  the base inner width of the window.
  1509.        Height - the base inner height of the window.
  1510.        XScale - the proposed x scale of the window.
  1511.        YScale - the proposed y scale of the window.
  1512.  
  1513.    RESULT
  1514.        Returns TRUE if the window will fit, and FALSE if not.
  1515.        if the XScale or YScale is <=0 it will also fail.
  1516.  
  1517.    SEE ALSO
  1518.        GetGUIScale(), CheckWindowSize()
  1519.  
  1520.  
  1521. extras.lib/OBSOLETE_CheckWindowSize       extras.lib/OBSOLETE_CheckWindowSize
  1522.  
  1523.    OBSOLETE
  1524.        Since OS3.5 uses Reaction/ClassAct - this code is obsolete
  1525.  
  1526.    NAME
  1527.        CheckWindowSize - See if a window will fit on a screen.
  1528.  
  1529.    SYNOPSIS
  1530.        windowfits = CheckWindowSize(Scr, Width, Height,
  1531.                                      XScale, YScale)
  1532.  
  1533.        BOOL CheckWindowSize(struct Screen *, WORD, WORD, 
  1534.                                     float, float);
  1535.  
  1536.    FUNCTION
  1537.        This function checks to see if a window will fit on a screen.
  1538.  
  1539.    INPUTS
  1540.        Scr - the Screen the window is destine for.
  1541.        Width - the base width of the window.
  1542.        Height - the base height of the window.
  1543.        XScale - the proposed x scale of the window.
  1544.        YScale - the proposed y scale of the window.
  1545.  
  1546.    RESULT
  1547.        Returns TRUE if the window will fit, and FALSE if not.
  1548.        if the XScale or YScale is <=0 it will also fail.
  1549.  
  1550.    SEE ALSO
  1551.        GetGUIScale(), CheckInnerWindowSize()
  1552.  
  1553. extras.lib/OBSOLETE_GetGUIScale               extras.lib/OBSOLETE_GetGUIScale
  1554.  
  1555.    OBSOLETE
  1556.        Since OS3.5 uses Reaction/ClassAct - this code is obsolete
  1557.  
  1558.    NAME
  1559.        GetGUIScale -- Find the appropriate scale for an
  1560.                       interface.
  1561.  
  1562.    SYNOPSIS
  1563.        success = GetGUIScale(TAttr, Strings, &XScale, &YScale)
  1564.  
  1565.        BOOL GetGUIScale(struct TextAttr *, struct GUI_String *,
  1566.                         float *, float *);
  1567.  
  1568.    FUNCTION
  1569.        This function figures out the minimum size an interface
  1570.        should be so that all of the Strings will fit.
  1571.  
  1572.    INPUTS
  1573.        TAttr - The TextAttr to be used for the strings.
  1574.        Strings - A NULL terminated array of GUI_String containing
  1575.                  the Strings to used in the interface and the maximum
  1576.                  size each string can be before the interface needs
  1577.                  to be enlarged.
  1578.        XScale - the address of a float to contain the X scale factor.
  1579.        YScale - the address of a float to contain the Y scale factor. 
  1580.  
  1581.    RESULT
  1582.        This function returns non-zero on success, and will have the X &
  1583.        YScale values set apropriately.  Returns NULL on failure if the
  1584.        font specified in TAttr can not be opened, and X & YScale will be
  1585.        set to -1.
  1586.  
  1587.    NOTES
  1588.        requires diskfont.library to be open.
  1589.  
  1590.        The reason this function sets X & YScale to -1 on failure is to
  1591.        also cause CheckWindowSize() and CheckInnerWindowSize to fail.
  1592.        This way you can simply:
  1593.        GetGUIScale(ta,strings,&xscale,&yscale)
  1594.        if(!CheckWindwoWidth(scr,winwidth,winheight,xscale,yscale))
  1595.        { ... revert to topaz.8 ... 
  1596.        }
  1597.  
  1598.        The GUI_String specifies the maximum size a string can be before
  1599.        the interface should be scaled horizontally.  For example, if you
  1600.        have a BUTTON_KIND gadget that is 100 pixels wide, then you may
  1601.        want to set the maximum size for the string in that gadget to 90.  
  1602.        (ie.
  1603.             struct GUI_String gs[]=
  1604.             {
  1605.               "Button Text", 90,
  1606.               0,0
  1607.             };
  1608.        )
  1609.  
  1610.    SEE ALSO
  1611.        MakeGadgets()
  1612.  
  1613. extras.lib/OBSOLETE_LG_AddGadgets           extras.lib/OBSOLETE_LG_AddGadgets
  1614.  
  1615.    OBSOLETE
  1616.        Since OS3.5 uses Reaction/ClassAct - this code is obsolete
  1617.  
  1618.    NAME
  1619.        LG_AddGadgets - Add gadgets to a window.
  1620.  
  1621.    SYNOPSIS
  1622.  
  1623.  
  1624.  
  1625.  
  1626.  
  1627.  
  1628.    FUNCTION
  1629.  
  1630.  
  1631.    INPUTS
  1632.  
  1633.    RESULT
  1634.  
  1635.    EXAMPLE
  1636.  
  1637.    NOTES
  1638.  
  1639.    BUGS
  1640.  
  1641.    SEE ALSO
  1642.  
  1643. extras.lib/OBSOLETE_LG_CreateGadgets     extras.lib/OBSOLETE_LG_CreateGadgets
  1644.  
  1645.    OBSOLETE
  1646.        Since OS3.5 uses Reaction/ClassAct - this code is obsolete
  1647.  
  1648.    NAME
  1649.        LG_CreateGadgets -- Create multiple Gadtools gadgets.
  1650.  
  1651.    SYNOPSIS
  1652.        gcontrol = LG_CreateGadgets(Tags)
  1653.  
  1654.        struct LG_Control *LG_CreateGadgets(Tag Tags, ...);
  1655.  
  1656.    FUNCTION
  1657.        Creates multiple Gadtools, with some layout options.
  1658.  
  1659.    INPUTS
  1660.        Tags (see <extras/layougtgt.h>)
  1661.  
  1662.          LG_LeftEdge, LG_XPos - Position of gadget
  1663.          LG_TopEdge,  LG_YPos - Position of gadget
  1664.              The position of the gadget will depend on these attributes
  1665.              and the LG_Justification attribute.  Also see the relational
  1666.              macros in <extras/layoutgt.h>
  1667.          LG_Width  - Gadget width
  1668.          LG_Height - Gadget height
  1669.  
  1670.            for the following see the NewGadget structure in 
  1671.            <libraries/gadtools.h>
  1672.          LG_GadgetText
  1673.          LG_TextAttr
  1674.          LG_GadgetID
  1675.          LG_Flags
  1676.          LG_VisualInfo
  1677.          LG_UserData
  1678.          LG_GadgetKind
  1679.          LG_GadgetTags
  1680.          LG_GadgetTagList
  1681.  
  1682.          LG_OffsetX - global offset from left of window
  1683.          LG_OffsetY - global offset from top of window 
  1684.             These two set to topleft of the domain.
  1685.             Also these will be added to LG_UseScreenOffsets
  1686.             or LG_UseWindowOffsets if set.
  1687.  
  1688.          LG_LabelFlags - see LGLF_ 
  1689.  
  1690.          LG_ScaleX - Multiply gadget width and position by these.
  1691.                      (percent * 65536)
  1692.          LG_ScaleY - Multiply gadget height and position by these.
  1693.                      (percent * 65536)
  1694.  
  1695.          LG_Justification - Sets the "handle" of the gadget.
  1696.  
  1697.          LG_UseScreenOffsets - Sets global offsets based on Window border 
  1698.                            dimensions specified in the Screen structure
  1699.          LG_UseWindowOffsets - Sets global offsets based on Window border 
  1700.                            dimensions
  1701.  
  1702.          LG_EraseRemoved - If set gadgets erase themselves when they are 
  1703.                            removed using LG_RemoveGadgets
  1704.  
  1705.          LG_KeyClass  - Not used 
  1706.          LG_KeyString - A string of characters that "activate" that 
  1707.               gadget, if not specified, LG_CreateGadget() will scan 
  1708.               the gadget label for the appropriate string.  This 
  1709.               attribute is cleared after each LG_CreateGadget
  1710.                attribute
  1711.          LG_ErrorCode - Not used
  1712.  
  1713.          LG_Bounds - set offsets or domain area for gadgets
  1714.          LG_BoundsLeft   - Left of domain. (Alias for LG_OffsetX)
  1715.          LG_BoundsTop    - Top of domain.  (Alias for LG_OffsetY)
  1716.          LG_BoundsWidth  - Width of domain.
  1717.          LG_BoundsHeight - Height of domain.
  1718.  
  1719.          LG_RelHorizGap - Gap between certain relative operations
  1720.          LG_RelVertGap  - Gap between certain relative operations
  1721.  
  1722.          LG_HorizCells - Sets the number of columns in a table.
  1723.          LG_VertCells - Sets the number of rows in a table. 
  1724.            Sets the number of cells in a table.  The table's pixel size
  1725.            is the current LG_Bound size.  These attributes work in 
  1726.            conjunction with the LG_REL_CELL_ macros defined in 
  1727.            <extras/layoutgt.h>
  1728.            
  1729.          LG_SkipGadgets - Skip the next ti_Data LG_CreateGadgets and 
  1730.            all Tags in between.
  1731.  
  1732.    RESULT
  1733.        returns NULL on failure, or a pointer the LG_Control structure 
  1734.        defined in <extras/layoutgt.h>
  1735.  
  1736.    EXAMPLE
  1737.        See the supplied example, if there are any.
  1738.  
  1739.    NOTES
  1740.        Gadgets created by LG_CreateGadgets() Must be freed using 
  1741.        LG_FreeGadgets OR Removed from it's Window using 
  1742.        LG_RemoveGadgets *BEFORE* the window is closed
  1743.  
  1744.    BUGS
  1745.  
  1746.    SEE ALSO
  1747.        LG_FreeGadgets, LG_RemoveGadgets, LG_AddGadgets, LG_RemoveGadgets,
  1748.  
  1749. extras.lib/OBSOLETE_LG_FreeGadgets         extras.lib/OBSOLETE_LG_FreeGadgets
  1750.  
  1751.    OBSOLETE
  1752.        Since OS3.5 uses Reaction/ClassAct - this code is obsolete
  1753.  
  1754.    NAME
  1755.        LG_FreeGadgets - free gadgets allocated be LG_CreateGadgets.
  1756.  
  1757.    SYNOPSIS
  1758.        LG_FeeeGadgets(Control)
  1759.  
  1760.        void LG_FreeGadgets(struct LG_Control);
  1761.  
  1762.    FUNCTION
  1763.        deallocates gadgets ans support structures allocated by 
  1764.         LG_CreateGadget
  1765.  
  1766.    INPUTS
  1767.        Con - pointer to structure returned by LG_CreateGadgets.
  1768.  
  1769.    RESULT
  1770.  
  1771.    EXAMPLE
  1772.  
  1773.    NOTES
  1774.        Gadgets created by LG_CreateGadgets() Must be freed using 
  1775.        LG_FreeGadgets OR Removed from it's Window using 
  1776.        LG_RemoveGadgets *BEFORE* the window is closed
  1777.  
  1778.    BUGS
  1779.  
  1780.    SEE ALSO
  1781.  
  1782. extras.lib/OBSOLETE_LG_GetGadget             extras.lib/OBSOLETE_LG_GetGadget
  1783.  
  1784.    OBSOLETE
  1785.        Since OS3.5 uses Reaction/ClassAct - this code is obsolete
  1786.  
  1787.    NAME
  1788.        LG_GetGadget - get a gadget pointer using Gadget ID.
  1789.  
  1790.    SYNOPSIS
  1791.  
  1792.  
  1793.  
  1794.  
  1795.  
  1796.  
  1797.    FUNCTION
  1798.  
  1799.  
  1800.    INPUTS
  1801.  
  1802.    RESULT
  1803.  
  1804.    EXAMPLE
  1805.  
  1806.    NOTES
  1807.  
  1808.    BUGS
  1809.  
  1810.    SEE ALSO
  1811.  
  1812. extras.lib/OBSOLETE_LG_GetGadgetAttrs   extras.lib/OBSOLETE_LG_GetGadgetAttrs
  1813.  
  1814.    OBSOLETE
  1815.        Since OS3.5 uses Reaction/ClassAct - this code is obsolete
  1816.  
  1817.    NAME
  1818.        LG_GetGadgetAttrs
  1819.  
  1820.    SYNOPSIS
  1821.  
  1822.  
  1823.  
  1824.  
  1825.  
  1826.  
  1827.    FUNCTION
  1828.  
  1829.  
  1830.    INPUTS
  1831.  
  1832.    RESULT
  1833.  
  1834.    EXAMPLE
  1835.  
  1836.    NOTES
  1837.  
  1838.    BUGS
  1839.  
  1840.    SEE ALSO
  1841.  
  1842. extras.lib/OBSOLETE_LG_RemoveGadgets     extras.lib/OBSOLETE_LG_RemoveGadgets
  1843.  
  1844.    OBSOLETE
  1845.        Since OS3.5 uses Reaction/ClassAct - this code is obsolete
  1846.  
  1847.    NAME
  1848.        LG_RemoveGadgets - remove gadgets from a window.
  1849.  
  1850.    SYNOPSIS
  1851.  
  1852.  
  1853.  
  1854.  
  1855.  
  1856.  
  1857.    FUNCTION
  1858.  
  1859.  
  1860.    INPUTS
  1861.  
  1862.    RESULT
  1863.  
  1864.    EXAMPLE
  1865.  
  1866.    NOTES
  1867.  
  1868.    BUGS
  1869.  
  1870.    SEE ALSO
  1871.  
  1872. extras.lib/OBSOLETE_LG_SetGadgetAttrs   extras.lib/OBSOLETE_LG_SetGadgetAttrs
  1873.  
  1874.    OBSOLETE
  1875.        Since OS3.5 uses Reaction/ClassAct - this code is obsolete
  1876.  
  1877.    NAME
  1878.        LG_SetGadgetAttrs - set gadget attrs.
  1879.  
  1880.    SYNOPSIS
  1881.  
  1882.  
  1883.  
  1884.  
  1885.  
  1886.  
  1887.    FUNCTION
  1888.  
  1889.  
  1890.    INPUTS
  1891.  
  1892.    RESULT
  1893.  
  1894.    EXAMPLE
  1895.  
  1896.    NOTES
  1897.  
  1898.    BUGS
  1899.  
  1900.    SEE ALSO
  1901.  
  1902. extras.lib/OBSOLETE_MakeGadgets               extras.lib/OBSOLETE_MakeGadgets
  1903.  
  1904.    OBSOLETE
  1905.        Since OS3.5 uses Reaction/ClassAct - this code is obsolete
  1906.  
  1907.    NAME
  1908.        MakeGadgets -- Minimal layout Gadtools gadgets.
  1909.  
  1910.    SYNOPSIS
  1911.        Gadget = MakeGedgets(Scr, VisualInfo, NumGadgets, NewGads, 
  1912.                NewGadTags, NewGadKinds, Gadgets, TextAttr, XScale,
  1913.                YScale)
  1914.  
  1915.        struct Gadget * MakeGadgets(struct Screen *,APTR ,ULONG,
  1916.                struct NewGadgets *, ULONG *, ULONG *,
  1917.                struct Gadget **, struct TextAttr *, float, float);
  1918.  
  1919.    FUNCTION
  1920.        This function will create Gadgets from an array of
  1921.        Gadtools NewGadgets, scaling the gadgets to the size
  1922.        specified.
  1923.  
  1924.    INPUTS
  1925.        Scr - This is the screen that the window containing these
  1926.                 gadgets are destine for.  This is only used to get
  1927.                 the WBorX values used to offset the gadgets from
  1928.                 the window border.  *Set this to NULL if the gadgets
  1929.                 are destine for a GimmeZeroZero window*.
  1930.        VisualInfo - VisualInfo pointer from gadtools/GetVisualInfo().
  1931.        NumGadgets - the number of gadgets to process.
  1932.        NewGads - array of struct NewGadget.
  1933.        NewGadTags - array of ULONGS to be processed as TagItems.
  1934.              All the gadget's tags are in this single array.
  1935.              (In the same fashion as GadToolsBox) 
  1936.              Individual tag arrays are NULL(TAG_DONE) terminated,
  1937.              And you may use TAG_MORE for additional Tags per gadget,
  1938.              but the array still must be NULL terminated.
  1939.        NewGadKinds - array of ULONGs, (BUTTON_KIND etc.)
  1940.        Gadgets - (struct Gadget **) Pointer to an array of
  1941.              Gadget pointers.  The Gadgets created by this
  1942.              function can be referenced by the ng_GadgetID of
  1943.              the source NewGadget.
  1944.        TextAttr - (struct TextAttr *) This TextAttr to used for
  1945.              gadgets whose ng_TextAttr is NULL.
  1946.        XScale - the x factor to scale the gadgets.
  1947.        YScale - the y factor to scale the gadgets.
  1948.              
  1949.    RESULT
  1950.        returns a pointer to the context from CreateContext()
  1951.        or NULL on failure.
  1952.  
  1953.    EXAMPLE
  1954.  
  1955.    NOTES
  1956.        requires diskfont, gadtools & utility libraries to
  1957.        be open.
  1958.  
  1959.        This function has a special flag for NewGadget->ng_Flags,
  1960.        NG_FITLABEL.  This flag tells the function to adjust the
  1961.        ng_LeftEdge and/or Width if the PLACETEXT_LEFT or RIGHT
  1962.        flags are set, and the ng_TopEdge and/or Height if the
  1963.        PLACETEXT_ABOVE or BELOW flags are set, so that the 
  1964.        ng_GadgetText will fit inside the area specified for the
  1965.        gadget.  You must also specify one of the PLACETEXT_?
  1966.        values or this will not work.
  1967.  
  1968.        For GimmeZeroZero windows set Scr to NULL.
  1969.        
  1970.        This function will not modify any of the arrays 
  1971.        (ie. NewGads, NewGadTags), this way if you have
  1972.        an interface that opens & closes multiple times
  1973.        (like commodities) you will not have to reinitialize
  1974.        the arrays.
  1975.  
  1976.        Every ng_GadgetID should be unique and none may have a
  1977.        larger value than the number of elements in the array
  1978.        pointed to by Gadgets.
  1979.  
  1980.        GTLV_ShowSelected works differently with this function.
  1981.        specify -1l for the display only gadget, specify the 
  1982.        gadget _id_ of the string gadget for the editable gadget
  1983.        (the string gadget must be created before the listview).
  1984.        Gadtools wants a NULL or poiner to a gadget for this value
  1985.        but this is taken care by this function. 
  1986.  
  1987.        Gadgets created by this function can be freed with a 
  1988.        call to FreeGadgets().
  1989.  
  1990.    BUGS
  1991.  
  1992.    SEE ALSO
  1993.        GetGUIScale()
  1994. extras.lib/OBSOLETEDrawBevelBoxes           extras.lib/OBSOLETEDrawBevelBoxes
  1995.  
  1996.    NAME
  1997.        DrawBevelBoxes -- draw a series of scaled bevel boxws.
  1998.  
  1999.    SYNOPSIS
  2000.        DrawBevelBoxes(Window, VisualInfo, BBoxes, NumBoxes,
  2001.              XScale, YScale);  
  2002.  
  2003.        void DrawBevelBoxes(struct Window *, APTR, 
  2004.              struct BevelBox *, LONG, float, float);
  2005.  
  2006.    FUNCTION
  2007.        Draws a series of scaled boxes.
  2008.  
  2009.    INPUTS
  2010.        Win - the Window to draw the bevel boxes in.
  2011.        VI - VisualInfo previously obtained by 
  2012.             gadtools.library/GetVisualInfoA()
  2013.        BBoxes - pointer to an array of struct BevelBox.
  2014.        NumBoxes - the number of entries in the array.
  2015.        XScale - 
  2016.        YScale - 
  2017.  
  2018.    EXAMPLE
  2019.  
  2020.    NOTES
  2021.  
  2022.    BUGS
  2023.  
  2024.    SEE ALSO
  2025.  
  2026. extras.lib/PD_PackData                                 extras.lib/PD_PackData
  2027.  
  2028.    NAME
  2029.        PD_PackData -- Pack supplied data into a memory block.
  2030.  
  2031.    SYNOPSIS
  2032.        packeddata = PD_PackData(Tags)
  2033.  
  2034.        struct PackedData *PD_PackData(Tag Tags, ... )
  2035.  
  2036.    FUNCTION
  2037.        Packs supplied data into a memory block, suitable for writing
  2038.        to disk.
  2039.  
  2040.    INPUTS
  2041.        Tags - a TagList.
  2042.            PD_Version - Adds a ULONG into the memory block.
  2043.                  Sets the version of the data.
  2044.  
  2045.            PD_BYTE - Adds a BYTE into the memory block.
  2046.            PD_UBYTE - Adds a UBYTE into the memory block.
  2047.  
  2048.            PD_WORD - Adds a WORD into the memory block. 
  2049.            PD_UWORD - Adds a UWORD into the memory block.
  2050.  
  2051.            PD_LONG - Adds a LONG into the memory block.
  2052.            PD_ULONG - Adds a ULONG into the memory block.
  2053.  
  2054.            PD_STRPTR - Adds a NULL terminated string into the memory block.
  2055.                  NULL pointers are supported
  2056.  
  2057.            PD_APTRSize - Adds the ULONG into the memory block,
  2058.                  Sets size for subsequent PD_APTRs.
  2059.            PD_APTR - Adds data into the memory block.  Size 
  2060.                  of data is set by previous PD_APTRSize.
  2061.                  if NULL, PD_APtrSize bytes are still written but are
  2062.                  unset.
  2063.  
  2064.            PD_BufferSize - Set the size of subsequent PD_Buffers
  2065.                  This tag does not add data to buffer.
  2066.  
  2067.            PD_Buffer     - Adds size of buffer, ULONG, followed by
  2068.                  data pointed to by ti_Data. 
  2069.                  See note for PD_UnpackData(()
  2070.            
  2071.            PD_MemoryFlags - Sets MemoryFlags for allocating 
  2072.  
  2073.  
  2074.    RESULT
  2075.  
  2076.    EXAMPLE
  2077.  
  2078.    NOTES
  2079.      Except for BYTEs, data is UWORD aligned, pads are inserted as needed.
  2080.  
  2081.      PackedData->pd_Data
  2082.      {
  2083.        ULONG privatelength
  2084.        {private bytes}
  2085.        user data
  2086.      }     
  2087.  
  2088.  
  2089.    BUGS
  2090.  
  2091.    SEE ALSO
  2092.  
  2093. extras.lib/PD_UnpackData                             extras.lib/PD_UnpackData
  2094.  
  2095.    NAME
  2096.        PD_UnpackData -- Unpack memory block.
  2097.  
  2098.    SYNOPSIS
  2099.        success = PD_UnpackData(Tags)
  2100.  
  2101.        BOOL *PD_UnpackData(Tag Tags, ... )
  2102.  
  2103.    FUNCTION
  2104.        Packs supplied data into a memory block, suitable for writing
  2105.        to disk.
  2106.  
  2107.    INPUTS
  2108.        Tags - a TagList.
  2109.            For most tags, ti_Data is a storage pointer, if NULL the 
  2110.            data is parsed but not stored.
  2111.  
  2112.            PD_Version   - (ULONG *) Reads the version of the data.
  2113.  
  2114.            PD_IfVersion - (ULONG) Once PD_Version has been read, you can
  2115.                this tag to stop data processing if PD_Version is lower than
  2116.                the value of this tag. 
  2117.  
  2118.            PD_BYTE - (BYTE *) Read a BYTE
  2119.            PD_UBYTE -(UBYTE *)
  2120.  
  2121.            PD_WORD - (WORD *) Read a WORD
  2122.            PD_UWORD -(UWORD *)
  2123.  
  2124.            PD_LONG - (LONG *) Read a LONG
  2125.            PD_ULONG -(LONG *)
  2126.  
  2127.            PD_STRPTR - (STRPTR *) AllocVec()s Memory for new STRPTR
  2128.                if PD_FreeSTRPTR is set, existing STRPTR is FreeVec()ed.
  2129.  
  2130.            PD_APTRSize - (ULONG *) Reads the amount of bytes that subsequent
  2131.                PD_APTRs read from the packed data.
  2132.  
  2133.            PD_APTR - Reads data from the memory block.  Size 
  2134.                  of data is set by previous PD_APTRSize.
  2135.                  if NULL, PD_APtrSize bytes are still written but are
  2136.                  unset.
  2137.  
  2138.            PD_BufferSize - (ULONG) Set data size for subsequent PD_Struct 
  2139.                  reads. This tag does not read any data, you must specify 
  2140.                  the size of your Buffer.
  2141.  
  2142.            PD_Buffer - (APTR) Data is copied to existing memory, the amount 
  2143.                  of data copied will be the lesser of PD_BufferSize or the
  2144.                  size stored in the packed data block.
  2145.            
  2146.            PD_MemoryFlags - Sets MemoryFlags for allocating 
  2147.  
  2148.  
  2149.    RESULT
  2150.  
  2151.    EXAMPLE
  2152.        PD_UnpackData(pd,
  2153.            PD_Version,     &dataversion, // store version number
  2154.            PD_BYTE,        &byte1,
  2155.            PD_BYTE,        0,            // byte not stored.
  2156.            PD_STRPTR,      &string,
  2157.  
  2158.            PD_IfVersion,   1, /* the following will only be read id PD_Versio
  2159. n >= 1 */
  2160.            PD_APTRSize,    10,
  2161.            PD_APTR,        &memchunk1,
  2162.            PD_APTR,        &memchunk2,
  2163.       
  2164.            PD_IfVersion,   2, /* the following will only be read id PD_Versio
  2165. n >= 2 */
  2166.            PD_STRUCT(mystruct),
  2167.       
  2168.            TAG_DONE,       0))
  2169.  
  2170.    BUGS
  2171.  
  2172.    SEE ALSO
  2173.  
  2174. extras.lib/PhraseInStr                                 extras.lib/PhraseInStr
  2175.  
  2176.    NAME
  2177.        PhraseInStr -- Find a phrase or word in a string.
  2178.  
  2179.    SYNOPSIS
  2180.        str = PhraseInStr(InStr, Phrase)
  2181.  
  2182.        STRPTR PhraseInStr(STRPTR , Phrase)
  2183.  
  2184.    FUNCTION
  2185.        Locates a phrase or word in a string.
  2186.  
  2187.    INPUTS
  2188.        InStr - String to search in.
  2189.        Phrase to search for.
  2190.  
  2191.    RESULT
  2192.        returns pointer to phrase in InStr or NULL.
  2193.  
  2194.    EXAMPLE
  2195.  
  2196.    NOTES
  2197.        case insensitive.
  2198.  
  2199.    BUGS
  2200.  
  2201.    SEE ALSO
  2202.  
  2203. extras.lib/ProcessTagList                           extras.lib/ProcessTagList
  2204.  
  2205.    NAME
  2206.        ProcessTagList -- Macro to process a taglist
  2207.  
  2208.    SYNOPSIS
  2209.        ProcessTagList(TagList, Tag, TState)
  2210.  
  2211.        TState=TagList; 
  2212.        while(Tag=NextTagItem(&TState))
  2213.  
  2214.    EXAMPLE
  2215.        void SomeFunc(struct TagItem *TagList)
  2216.        {
  2217.          struct TagItem *tag, *tstate;
  2218.  
  2219.          ProcessTagList(TagList,tag,tstate)
  2220.          {
  2221.            seitch(tag->ti_Tag)
  2222.            {
  2223.              case GA_Left:
  2224.                ...
  2225.                break;
  2226.              etc...
  2227.            }
  2228.          }
  2229.        }
  2230.  
  2231. extras.lib/RenderText                                   extras.lib/RenderText
  2232.  
  2233.    NAME
  2234.        RenderTextA -- Write text into a RastPort.
  2235.        RenderText -- varargs stub.
  2236.  
  2237.    SYNOPSIS
  2238.        reserved = RenderTextA( RP, String, TagList)
  2239.  
  2240.        LONG RenderTextA( struct RastPort *, STRPTR, 
  2241.                          struct TagItem *);
  2242.  
  2243.        reserved = RenderText( RP, String, Tags, ... )
  2244.  
  2245.        LONG RenderText( struct RastPort *, STRPTR, 
  2246.                         Tag, ...);
  2247.  
  2248.    FUNCTION
  2249.        Writes text into a Rastport, basically an interface
  2250.        to the graphics.library/Text() function.
  2251.  
  2252.    INPUTS
  2253.        RP - rastport to write to.
  2254.        String - the string to write.
  2255.        TagList - an array of TagItems.
  2256.          RT_Baseline - baseline of the cursor. 
  2257.                        default RastPort->cp_y
  2258.          RT_XPos     - horizontal position of the cursor.
  2259.                        default RastPort->cp_x
  2260.          RT_MaxWidth - maximum pixel length of text, excess
  2261.                        characters will be clipped.
  2262.          RT_Justification - RTJ_???  (default _LEFT)
  2263.          RT_TextFont - struct TextFont * from OpenFont()
  2264.          RT_Strlen   - number of characters in string.
  2265.          RT_TextLength - (ULONG *) Width in pixels of printed texted.
  2266.  
  2267.  
  2268.    RESULT
  2269.        Number of characters drawn.
  2270.  
  2271.    BUGS
  2272.        RenderText does not reset a RastPort's TextFont
  2273.        after using RT_TextFont. 
  2274.  
  2275.    SEE ALSO
  2276.        mlr_rendertext.image image class.
  2277.  
  2278. extras.lib/str_Strip                                     extras.lib/str_Strip
  2279.  
  2280.    NAME
  2281.        str_Strip - Remove leading and trailing white spaces.
  2282.  
  2283.    SYNOPSIS
  2284.        str_Strip(Str)       
  2285.  
  2286.        void Strip(STRPTR);
  2287.  
  2288.    FUNCTION
  2289.        This function removes leading and trailing whites-paces
  2290.        from a string.  White-spaces are determined by the 
  2291.        IsWhiteSpace() function.
  2292.  
  2293.    INPUTS
  2294.        Str - a null terminated string pointer.
  2295.  
  2296.    RESULT
  2297.        none.
  2298.  
  2299.    EXAMPLE
  2300.  
  2301.    NOTES
  2302.        Modifies existing string memory.
  2303.  
  2304.    BUGS
  2305.        Will not work on NNStr used by other some functions in 
  2306.        the extras.lib.
  2307.  
  2308.    SEE ALSO
  2309.        IsWhiteSpace().
  2310.  
  2311. extras.lib/StrIStr                                         extras.lib/StrIStr
  2312.  
  2313.    NAME
  2314.        StrIStr -- search for a string in another string, case 
  2315.                   insenseitive.
  2316.  
  2317.    SYNOPSIS
  2318.        StrIStr(InStr,SearchStr)
  2319.  
  2320.        STRPTR StrIStr(STRPTR InStr,STRPTR SearchStr);
  2321.  
  2322.    FUNCTION
  2323.        Seach for a string inside another, case insensitive.
  2324.  
  2325.    INPUTS
  2326.        InStr - the string to search in.
  2327.        SearchStr - the string to search for.
  2328.  
  2329.    RESULT
  2330.        returns a pointer in InStr that matches SearchStr, or NULL
  2331.        if no match was found.
  2332.  
  2333. extras.lib/tag_AddTag                                   extras.lib/tag_AddTag
  2334.  
  2335.    NAME
  2336.        tag_AddTag -- Add a tag toa taglist.
  2337.  
  2338.    SYNOPSIS
  2339.        ok = tag_AddTag(TagList, Tag, Data)
  2340.  
  2341.        BOOL tag_AddTag(struct TagItem *, ULONG, ULONG);
  2342.  
  2343.    FUNCTION
  2344.        Add a tag pair to a taglist created with tag_AllocTags()
  2345.  
  2346.    INPUTS
  2347.        TagList - TagList created with tag_AllocTags()
  2348.        Tag - ti_Tag value
  2349.        Data - ti_Data value
  2350.  
  2351.    RESULT
  2352.        non zero if the tag was added.
  2353.        failure can be due to under sized taglist.
  2354.  
  2355.    EXAMPLE
  2356.        see tag_AllocTags()
  2357.  
  2358.    NOTES
  2359.        Don't tag_AddTag TAG_IGNORE, TAG_DONE, TAG_MORE, TAG_SKIP.
  2360.        This function will only effect the specified TagList, and 
  2361.        not any other lists referenced by TAG_MORE.
  2362.        This function overwrites existing same tags.
  2363.  
  2364.    SEE ALSO
  2365.        tag_AllocTags()
  2366.  
  2367. extras.lib/tag_AddTags                                 extras.lib/tag_AddTags
  2368.  
  2369.    NAME
  2370.        tag_AddTags -- Add a taglist to a taglist.
  2371.  
  2372.    SYNOPSIS
  2373.        ok = tag_AddTags(TagList, Tag, Data)
  2374.  
  2375.        BOOL tag_AddTags(struct TagItem *, ULONG, ULONG);
  2376.  
  2377.    FUNCTION
  2378.        Add a taglist to a taglist created with tag_AllocTags()
  2379.  
  2380.    INPUTS
  2381.        TagList - TagList created with tag_AllocTags()
  2382.        NewTags - Tags to add to TagList
  2383.  
  2384.    RESULT
  2385.        non zero if the tag was added.
  2386.        failure can be due to under sized taglist.
  2387.  
  2388.    EXAMPLE
  2389.        see tag_AllocTags()
  2390.  
  2391.    NOTES
  2392.        This function will only effect the specified TagList, and 
  2393.        not any other lists referenced by TAG_MORE.
  2394.        This function overwrites existing same tags.
  2395.  
  2396.    SEE ALSO
  2397.        tag_AllocTags()
  2398.  
  2399. extras.lib/tag_AllocTags                             extras.lib/tag_AllocTags
  2400.  
  2401.    NAME
  2402.        tag_AllocTags -- Allocate blank Tag List
  2403.  
  2404.    SYNOPSIS
  2405.        taglist = tag_AllocTags(TagCount)
  2406.  
  2407.        struct TagItem *tag_AllocTags(ULONG);
  2408.  
  2409.    FUNCTION
  2410.        Allocate tag space for use with other tag_? functions.
  2411.  
  2412.    INPUTS
  2413.        TagCount - Number of blank tags to allocate.
  2414.  
  2415.    RESULT
  2416.        An empty tag space ending with TAG_DONE, or NULL.
  2417.  
  2418.    EXAMPLE
  2419.  
  2420.    NOTES
  2421.  
  2422.    BUGS
  2423.  
  2424.    SEE ALSO
  2425.  
  2426. extras.lib/tag_ClearNumTags                       extras.lib/tag_ClearNumTags
  2427.  
  2428.    NAME
  2429.        tag_ClearTags -- Clear a TagList
  2430.  
  2431.    SYNOPSIS
  2432.        void tag_ClearTags(TagList, TagCount)
  2433.  
  2434.        tag_ClearTags(struct TagItem *, ULONG);
  2435.  
  2436.    FUNCTION
  2437.        Clears the TagList of all data.
  2438.  
  2439.    INPUTS
  2440.        TagList - Allocated with tag_AllocTags()
  2441.        TagCount - Number of blank tags to allocate.
  2442.  
  2443.    EXAMPLE
  2444.        see tag_AllocTags()
  2445.  
  2446.    NOTES
  2447.        This function is called by tag_AllocTags(), so
  2448.        the taglist is cleared when allocated.
  2449.        This function will only effect the specified TagList, and 
  2450.        not any other lists referenced by TAG_MORE.
  2451.  
  2452.    BUGS
  2453.  
  2454.    SEE ALSO
  2455.        see tag_AllocTags()
  2456.  
  2457. extras.lib/tag_ClearTags                             extras.lib/tag_ClearTags
  2458.  
  2459.    NAME
  2460.        tag_ClearTags -- Clear a TagList
  2461.  
  2462.    SYNOPSIS
  2463.        void tag_ClearTags(TagList)
  2464.  
  2465.        tag_ClearTags(struct TagItem *);
  2466.  
  2467.    FUNCTION
  2468.        Clears the TagList of all data.
  2469.  
  2470.    INPUTS
  2471.        TagList - Allocated with tag_AllocTags()
  2472.  
  2473.    EXAMPLE
  2474.        see tag_AllocTags()
  2475.  
  2476.    NOTES
  2477.        This function will only effect the specified TagList, and 
  2478.        not any other lists referenced by TAG_MORE.
  2479.  
  2480.    BUGS
  2481.  
  2482.    SEE ALSO
  2483.        see tag_AllocTags()
  2484.  
  2485. extras.lib/tag_CountUserTags                     extras.lib/tag_CountUserTags
  2486.  
  2487.    NAME
  2488.        tag_CountUserTags -- number of user tags
  2489.  
  2490.    SYNOPSIS
  2491.        ULONG tag_CountUserTags(TagList)
  2492.  
  2493.        tag_CountUserTags(struct TagItem *);
  2494.  
  2495.    FUNCTION
  2496.        Count the number of user tags.
  2497.  
  2498.    INPUTS
  2499.        TagList - Allocated with tag_AllocTags().
  2500.  
  2501. extras.lib/tag_FreeTags                               extras.lib/tag_FreeTags
  2502.  
  2503.    NAME
  2504.        tag_FreeTags -- Clear a TagList
  2505.  
  2506.    SYNOPSIS
  2507.        void tag_FreeTags(TagList)
  2508.  
  2509.        tag_FreeTags(struct TagItem *);
  2510.  
  2511.    FUNCTION
  2512.        Frees the TagList.
  2513.  
  2514.    INPUTS
  2515.        TagList - Allocated with tag_AllocTags().
  2516.  
  2517.    EXAMPLE
  2518.        see tag_AllocTags()
  2519.  
  2520.    SEE ALSO
  2521.        see tag_AllocTags()
  2522.  
  2523. extras.lib/tag_RemTag                                   extras.lib/tag_RemTag
  2524.  
  2525.    NAME
  2526.        tag_RemTag -- Removea a tag to a taglist.
  2527.  
  2528.    SYNOPSIS
  2529.        ok = tag_RemTag(TagList, Tag)
  2530.  
  2531.        BOOL tag_RemTag(struct TagItem *, ULONG);
  2532.  
  2533.    FUNCTION
  2534.        Find and remove a tag from a taglist.
  2535.  
  2536.    INPUTS
  2537.        TagList - TagList created with tag_AllocTags()
  2538.        Tag - ti_Tag value
  2539.  
  2540.    RESULT
  2541.        non zero if the tag was found and removed.
  2542.  
  2543.    EXAMPLE
  2544.        see tag_AllocTags()
  2545.  
  2546.    NOTES
  2547.        Don't tag_AddTag TAG_IGNORE, TAG_DONE, TAG_MORE, TAG_SKIP.
  2548.        This function will only effect the specified TagList, and 
  2549.        not any other lists referenced by TAG_MORE.
  2550.  
  2551.    SEE ALSO
  2552.        tag_AllocTags()
  2553.  
  2554. extras.lib/tag_TagDone                                 extras.lib/tag_TagDone
  2555.  
  2556.    NAME
  2557.        tag_TagDone -- End the TagList with TagDone
  2558.  
  2559.    SYNOPSIS
  2560.        void tag_FreeTags(TagList)
  2561.  
  2562.        tag_FreeTags(struct TagItem *);
  2563.  
  2564.    FUNCTION
  2565.        Ends the taglist with TAG_MORE and link the list to MoreTags
  2566.  
  2567.    INPUTS
  2568.        TagList - Allocated with tag_AllocTags().
  2569.  
  2570.    EXAMPLE
  2571.        see tag_AllocTags()
  2572.  
  2573.    SEE ALSO
  2574.        see tag_AllocTags()
  2575.  
  2576. extras.lib/tag_TagMore                                 extras.lib/tag_TagMore
  2577.  
  2578.    NAME
  2579.        tag_TagMore -- End the TagList with TagMore
  2580.  
  2581.    SYNOPSIS
  2582.        void tag_FreeTags(TagList, MoreTags)
  2583.  
  2584.        tag_FreeTags(struct TagItem *, struct TagItem *);
  2585.  
  2586.    FUNCTION
  2587.        Ends the taglist with TAG_MORE and link the list to MoreTags
  2588.  
  2589.    INPUTS
  2590.        TagList - Allocated with tag_AllocTags().
  2591.        MoreTags - Tags to link
  2592.  
  2593.    EXAMPLE
  2594.        see tag_AllocTags()
  2595.  
  2596.    SEE ALSO
  2597.        see tag_AllocTags()
  2598.  
  2599. extras.lib/thread_EndThread                       extras.lib/thread_EndThread
  2600.  
  2601.    NAME
  2602.        thread_EndThread -- end a thread.
  2603.  
  2604.    SYNOPSIS
  2605.  
  2606.  
  2607.  
  2608.  
  2609.  
  2610.  
  2611.    FUNCTION
  2612.  
  2613.  
  2614.    INPUTS
  2615.  
  2616.    RESULT
  2617.  
  2618.    EXAMPLE
  2619.  
  2620.    NOTES
  2621.        Note, this function waits for a reply.
  2622.  
  2623.    BUGS
  2624.  
  2625.    SEE ALSO
  2626.  
  2627. extras.lib/thread_PutTMsg                           extras.lib/thread_PutTMsg
  2628.  
  2629.    NAME
  2630.        thread_PutTMsg --
  2631.  
  2632.    SYNOPSIS
  2633.        success=thread_PutTMsg(Thread, Msg)
  2634.  
  2635.        BOOL thread_PutTMsg(struct Thread *, struct ThreadMessage *)
  2636.  
  2637.    FUNCTION
  2638.        Send a message to the thread, this function does not
  2639.        wait for a reply.  You must supply a reply port for
  2640.        your message.
  2641.  
  2642.    INPUTS
  2643.        Thread - to send message to
  2644.        Msg - Message to send.
  2645.  
  2646.    RESULT
  2647.        Non-zero if message successfully sent.     
  2648.  
  2649.    NOTES
  2650.        Note, this function does not wait for a reply.
  2651.  
  2652. extras.lib/thread_PutTMsg_Sync                 extras.lib/thread_PutTMsg_Sync
  2653.  
  2654.    NAME
  2655.        thread_PutTMsg_Sync -- Send a ThreadMessage to a thread.
  2656.  
  2657.    SYNOPSIS
  2658.        success=thread_PutTMsg_Sync(Thread, Msg)
  2659.  
  2660.        BOOL thread_PutTMsg_Sync(Thread, struct ThreadMessage);
  2661.  
  2662.    FUNCTION
  2663.        Send a message to the thread, this function will
  2664.        wait for a reply.  The messages reply port will be changed.
  2665.  
  2666.    INPUTS
  2667.        Thread - to send message to
  2668.        Msg - Message to send.
  2669.  
  2670.    RESULT
  2671.        Non-zero if message successfully sent.
  2672.  
  2673.    NOTES
  2674.        Note, this function waits for a reply.
  2675.        replyport is changed
  2676.  
  2677.    BUGS
  2678.  
  2679.    SEE ALSO
  2680.  
  2681. extras.lib/thread_PutTMsg_TagList           extras.lib/thread_PutTMsg_TagList
  2682.  
  2683.    NAME
  2684.        thread_PutTMsg_TagList -- Send a TagListTMsg to a thread (varargs)
  2685.  
  2686.    SYNOPSIS
  2687.        RetVal = thread_PutTMsg_TagList(Thread, Command, Tags ... )
  2688.  
  2689.        ULONG thread_PutTMsg_TagList(struct Thread, ULONG, Tag, ...);
  2690.  
  2691.    FUNCTION
  2692.        Sends a message to the task, using the TMsg_TagList structure.
  2693.        Waits for a reply, then returns tm_RetVal.
  2694.  
  2695.    INPUTS
  2696.        Thread - (struct Thread *)
  2697.        Command - Command ID.
  2698.        Tag - 
  2699.  
  2700.    RESULT
  2701.        returns zero on failure, otherwise returns value of TMsg_TagList.tm_Re
  2702. tVal.
  2703.  
  2704.    NOTES
  2705.        Note, this function waits for a reply.
  2706.  
  2707. extras.lib/thread_StartThread                   extras.lib/thread_StartThread
  2708.  
  2709.    NAME
  2710.        thread_StartThread -- Create a thread.
  2711.  
  2712.    SYNOPSIS
  2713.        Thread thread_StartThread(Tags)
  2714.  
  2715.        struct Thread *thread_StartThread(Tag, ... );
  2716.  
  2717.    FUNCTION
  2718.        Creates and starts a new thread (Process).
  2719.  
  2720.    INPUTS
  2721.        Tags - TagList (on stack)
  2722.          TA_Name - Name of thread, defaults to "Thread".
  2723.          TA_Stack - Stacksize, default 8192.
  2724.          TA_Priority - default -1
  2725.          TA_MsgHandler - Function to handle thread messages.
  2726.          TA_UserData - (APTR)
  2727.          TA_A6 - (struct Library *) 
  2728.  
  2729.    RESULT
  2730.        Pointer to the newly created Thread, or NULL on failure.
  2731.        The Thread stucture is ReadOnly, except for
  2732.          t_Node, UserData and ThreadData
  2733.  
  2734.    NOTES
  2735.        It's suggested that ThreadData be used store local data
  2736.        for the Thread.
  2737.  
  2738.    BUGS
  2739.        1.3 - Made functional, some timing issues caused crashes.
  2740.  
  2741.    SEE ALSO
  2742.  
  2743. extras.lib/UpdateProgressMeterA               extras.lib/UpdateProgressMeterA
  2744.  
  2745.    NAME
  2746.        UpdateProgressMeterA -- Change ProgressMeter attributes.
  2747.        UpdateProgressMeter -- varargs stub.
  2748.  
  2749.    SYNOPSIS
  2750.        numProcessed UpdateProgressMeterA(PM,TagList)
  2751.  
  2752.        LONG UpdateProgressMeterA(ProgressMeter ,struct TagItem *);
  2753.  
  2754.        numProcessed UpdateProgressMeter(PM,FirstTag)
  2755.  
  2756.        LONG UpdateProgressMeter(ProgressMeter , Tag, ...);
  2757.  
  2758.    FUNCTION
  2759.        Updates a ProgressMeter's attributes  and refreshes
  2760.        it as neccessary.
  2761.  
  2762.    INPUTS
  2763.        PM - Pointer to an existing ProgressMeter or NULL.
  2764.        TagList - TagList of attributes to change or NULL.
  2765.            Only these four tags are processed.
  2766.              PM_QueryCancel
  2767.              PM_MeterValue
  2768.              PM_LowValue
  2769.              PM_HighValue
  2770.  
  2771.    RESULT
  2772.        returns the number of tags processed.
  2773.  
  2774.    EXAMPLE
  2775.  
  2776.    NOTES
  2777.      requires diskfont, exec, gadtools, graphics, intuition & utility
  2778.      libraries to be open.
  2779.  
  2780.    BUGS
  2781.  
  2782.    SEE ALSO
  2783.      AllocProgressMeterA(), FreeProgressMeter() 
  2784.  
  2785. Macro/nns_ProcessNNStr                                 Macro/nns_ProcessNNStr
  2786.  
  2787.    NAME
  2788.        nns_ProcessNNStr(NNStr, Str)
  2789.  
  2790.    SYNOPSIS
  2791.        nns_ProcessNNStr(NNStr, Str)
  2792.  
  2793.    FUNCTION
  2794.  
  2795.    INPUTS
  2796.  
  2797.    RESULT
  2798.  
  2799.    EXAMPLE
  2800.        STRPTR NNStr, str;
  2801.        
  2802.        ProcessNNStr(NNStr,str)
  2803.        {
  2804.          printf("%s\n",str);
  2805.        }
  2806.  
  2807.    NOTES
  2808.  
  2809.    BUGS
  2810.  
  2811.    SEE ALSO
  2812.  
  2813.